Concrete5 Command Line executable for Maintenance and Repair?

Permalink
Is there a command line executable for website maintenance and repair?
I would like to do such things as
- clear cache
- clean up my database
- fix database caps
- check & edit version numbers in various files
- check site.php and edit appropriately
- etc
- compress and backup the website except the concrete folder and update folder
- do all those little weird things that need to be done??

fcgleason
 
JohntheFish replied on at Permalink Best Answer Reply
JohntheFish
I have never used it, but see
https://github.com/danklassen/consh...

There may be other possibilities on
http://www.concrete5.org/developers/open-source/...
fcgleason replied on at Permalink Reply
fcgleason
Thank you John the Fish. Looks very much developed. Do you know if it will work on Centos, also I use Win7 Laptop.... do you think it will work?

I'd really like a cmd.ex utility to show all the version numbers for
site.php define('DIRNAME_APP_UPDATED', 'concrete5.x.x.x');
current db SITE_APP_VERSION 5.x.x.x
current db APP_VERSION_LATEST 5.x.x.x

Also I think this should be in an 'About' Tab in the Dashboard.
With all the information about PHP settings, Apache version, Mysql version, etc.
Thanks.


------
In figuring out why my upgrade did not work I got down a process for some of the key essentials that you must know. It turned out I had the wrong database or was pointed to the wrong concrete version. Here is the process.

Install phpMyAdmin and Filezilla and get permissions setup for access.

First off clear your cache (This was a problem, had no access to dashboard)
Dashboard->Sitewide Settings->Speed Settings "Clear Cache"
Then delete any/all files in /files/cache

Filezilla check folder permissions.
/files 777
No /files/trash folder
Tried clearing the /files/cache and /tmp folders.

If the problem persists Filezilla
At the root of your site you should have a folder named /updates/
Do you have a folder name concrete5.X.X.X in it?
Do you have any other folders in there? Which ones?
Also, in your /config/site.php does it have a line like define('DIRNAME_APP_UPDATED'... ?

Using Filezilla to view/edit http://yoursite.com/ site.php
<?php
define('DB_SERVER', 'localhost');
define('DB_USERNAME', 'username');
define('DB_PASSWORD', 'password');
define('DB_DATABASE', 'concrete');
define('BASE_URL', 'http://yoursite.com');
define('DIR_REL', '');
define('PASSWORD_SALT', 'long salt code here');
define('DIRNAME_APP_UPDATED', 'concrete5.x.x.x');

Using PhpMyAdmin
http://yoursite.com/phpmyadmin/...
password etc
Find concrete version listed, check the "Config" table for
SITE_APP_VERSION 5.x.x.x
APP_VERSION_LATEST 5.x.x.x
What do those report?

It's possible that your database, config or cache may be set to or giving out different version numbers.

When I got all three Version numbers aligned I could login and the site worked. I had to drop all tables in the 'concrete' database and load successive databases downloaded from
Database Backup
/files/backups

Until I had two versions ok. Then I pointed the site.php to the proper version.

In phpmyadmin I was limited to 2mb so I used Jzip to compress the database files to <2mb with db-xxxx.sql.bz2 at the end. phpMyAdmin then uploaded the db successfully and repopulated the tables.

------------
Compress the Database - Use Jzip or 7zip to compress the file to file.sql.bz2
phpMyAdmin allows three compression types i.e. .zip , .gzip and .bzip2
Uploaded the compressed bzip2 file using phpMyAdmin.
NOTE: phpMyAdmin import page clearly instructs that the compressed filename should be like filename.sql.bz2 . It should not be like filename.bz2 .

Increase size of PhpMyAdmin upload
With apache2 and php5 installed you need to make three changes in the file
Usually in servers like CentOs it is located at /etc/php.ini.
sudo gedit /etc/php5/apache2/php.ini
Search for entry post_max_size = 2M where you need to enter a larger number than the size of your database (15M in this case) i.e. 25M, next edit memory_limit and give a larger number than the one given to post_max_size. At last, edit the entry upload_max_filesize with a value smaller than post_max_size.
Starting from bigger values the order should go like this
memory_limit 128mb
post_max_size 21 mb
upload_max_filesize 20mb
post_max_size and memory_limit need to be larger than upload_max_filesize.
May need to change Maximum execution time setting
Restart apache (for ex: sudo /etc/init.d/apache2 restart) and you are set.
Don't forget to Restart Apache Services for changes to get applied
upload a file to the server via scp, ftp, or your favorite file transfer method. PhpMyAdmin is then able to import the files from the temporary directory

-----
To Backup DB and Website
Dashboard >> System & Settings >> Backup & Restore >> Backup Database
Run the backup of the Database resulting file to local machine.
Setup and use a FTP or SFTP client, copy the public folder. It takes time.

Use Virtualmin Backup compress and backup entire website to your harddrive
Use 'full' backup or 'partial' entire 'home' directory with the database in one place.
Concrete5 has many files and ftp-ing can often be a slow process.
The backup are zipped up and often only take a few minutes to download.
JohntheFish replied on at Permalink Reply
JohntheFish
I have never used it and have no idea what systems it is compatible with.

I suggest you contact the developer through github, or just give it a try and see what happens.

For your other issue, please start a new thread.