Run a wiki maintenance script
| Run a wiki maintenance script|
Organic Design procedure
All the maintenance scripts are in the wiki/maintenance directory of the installation for the MediaWiki version of the wiki you want to run the script on. The following steps should be followed to run the script.
- Backup the wiki
- Put the wiki down for maintenance so that the database is not accessed while the script is running
- Change the wiki symlink in the /var/www/wikis structure for the wiki to the new codebase.
- In the LocalSettings.php file in the codebase directory, the $domain variable must be set to the domain of the wiki for which the maintenance script is being run for. This should be included before the inclusion of wikia.php.
- Execute the script using for example, php maintenance/update.php
- Re-enable the site again by reversing the LocalSettings.php modifications above.
If there are problems you may have to restore the wiki from the backup.
Pre 1.16 Wikis
Before MediaWiki 1.16 there was a file called AdminSettings.php that needed to have the $wgDBadminuser and $wgDBadminpassword (and in OD/Wikia also the $domain setting) in it instead of putting them directly into the LocalSettings.php file.