Help:Upgrading MediaWiki
From USAFA Rugby Alumni
Notes for upgrading MediaWiki on shared server at InMotion.
[edit]
Assuming new version of MediaWiki has been uploaded into a directory on shared server
- Backup database using PhpMyAdmin on InMotion's cPanel. Backup will be downloaded to local machine from which upgrade is being performed.
- Backup current version of MediaWiki on shared server.
- SSH into shared server and execute follow command from root directory of MediaWiki instance - cp -r * <path to backup directory>
- After backing up, check to insure all files were copied - diff -rq <root of current MediaWiki> <path to backup directory>
- Stop access to current version by executing following command from root directory of current MediaWiki instance - mv LocalSettings.php LocalSettings.php.old
- Check LocalSettings.php in the new instance to make sure that all data is accurate to allow it to run on the shared server. See below for full listing of LocalSettings.php that will need to conform
- Point browser to new version - http://usafarugbyalumni.com/<path to new instance> and run basic tests to confirm all is ok and pages on new instance match pages on current instance.
Notes:
- list only directories ls -d */
- list only files ls | grep -v '^d'
- compare directories with exclusions and file names only diff -rq --exclude <dirname> <first dir> <second dir>
- copy recursively from one directory to another and preserver attributes cp avr
- used for final copy from new MediaWiki instance to current directory
- https://www.cyberciti.biz/faq/copy-folder-linux-command-line/