MediaWiki/Upgrade/REL1 25 to REL1 26: Difference between revisions
No edit summary |
update |
||
| Line 1: | Line 1: | ||
=== Overview === | === Overview === | ||
Last updated in 2008, it was time to revisit this page and make some new notes. Even though the README, UPGRADE and online help are very detailed, I find it helpful to note my personal preferences, observations, and clarifications. Still, for the do-it-yourself types, the [[mw:Manual:Upgrading#Using_Git|official docs]] are the best resource. If you need professional help with MediaWiki, then contact [[User:Freephile|Greg Rundlett]] | |||
The process obviously started with downloading the source from the web. However, since the wikipedia project uses the continuous integration method of development (meaning they always run their own latest code), I | The process obviously started with downloading the source from the web. However, since the wikipedia project uses the continuous integration method of development (meaning they always run their own latest code), I follow the same practice and run off either the latest release branch or master from the [[git]] repository. So, I simply did a <code>composer update --no-dev && git fetch</code> to prepare for an upgrade. | ||
=== Consult the release notes === | === Consult the release notes === | ||
| Line 16: | Line 14: | ||
=== Backup first === | === Backup first === | ||
I copied my filesystem as a backup. | I copied my filesystem as a backup and testing ground. | ||
I | For the database, I have a backup script that in addition to timed backups, will create a spot backup on demand: <code>~/bin/backup.db.sh mediawiki</code> | ||
=== Perform the file upgrade === | === Perform the file upgrade === | ||
The mechanism for loading extensions has changed, so the old 'requires' can be replaced by 'wfLoadExtension' function <code>require_once\( *"\$IP/extensions/.*/([^/]*)" * \); wfLoadExtension( '\1' );</code> | |||
You | With the software downloaded (git fetch), and a check to see if you've modified anything (git status), you can simply switch the branch you're on <code>git checkout -b REL1_26 origin/REL1_26</code> and then do the database upgrade. | ||
You must preserve: | |||
* The LocalSettings.php file | * The LocalSettings.php file | ||
* | * DatabaseSettings file, where it exists | ||
* The extensions directory | * The extensions directory | ||
* The images directory | * The images directory | ||
If using an alternative uploads directory, preserve this; and if using custom | If using an alternative uploads directory, preserve this; and if using custom skins, preserve these too. The core code is now updated. | ||
skins, preserve these too. The core code is now updated. | |||
=== Perform the database upgrade === | === Perform the database upgrade === | ||
| Line 66: | Line 58: | ||
=== Change the wiki pointer === | === Change the wiki pointer === | ||
In order to quickly upgrade, revert or take the site offline, | In order to quickly upgrade, revert or take the site offline, you can simply use a symbolic link and point that to the correct target folder. However, note that this can present problems for your extensions when <code>$IP</code> is not defined correctly | ||
=== Test === | === Test === | ||