User:WikiMaster/Wiki - Installation & Upgrading: Difference between revisions
Jump to navigation
Jump to search
WikiMaster (talk | contribs) |
WikiMaster (talk | contribs) (→Interface: Changed "Interface" section to "Logo & Favicon Settings." + Added Read-Only Mode section.) |
||
(13 intermediate revisions by the same user not shown) | |||
Line 4: | Line 4: | ||
* Automated MySQL Backup Tool - [http://sourceforge.net/projects/automysqlbackup/ AutoMySQLBackup] | * Automated MySQL Backup Tool - [http://sourceforge.net/projects/automysqlbackup/ AutoMySQLBackup] | ||
* MySQL dump tool - [http://dev.mysql.com/doc/refman/5.0/en/mysqldump.html mysqldump — A Database Backup Program] | * MySQL dump tool - [http://dev.mysql.com/doc/refman/5.0/en/mysqldump.html mysqldump — A Database Backup Program] | ||
: Consider making the Wiki read-only before creating the backup - see [[mediawikiwiki:Manual:$wgReadOnly|Manual:$wgReadOnly]]. This makes sure all parts of your backup are consistent (some of your installed extensions may write data nonetheless). | * [http://www.siteground.com/tutorials/php-mysql/mysql_export.htm MySQL Export: How to backup your MySQL database?] | ||
: You can easily create a dump file(export/backup) of a database using the '''[[wikipedia:phpMyAdmin|phpMyAdmin]]''' tool. | |||
* Consider making the Wiki read-only before creating the backup - see [[mediawikiwiki:Manual:$wgReadOnly|Manual:$wgReadOnly]]. This makes sure all parts of your backup are consistent (some of your installed extensions may write data nonetheless). | |||
; [[mediawikiwiki:Developer hub|Developer hub]] | ; [[mediawikiwiki:Developer hub|Developer hub]] | ||
; [[mediawikiwiki:Sysadmin hub|Sysadmin hub]] | ; [[mediawikiwiki:Sysadmin hub|Sysadmin hub]] | ||
* [[mediawikiwiki:Manual:Upgrading|Manual:Upgrading]] | * [[mediawikiwiki:Manual:Upgrading|Manual:Upgrading]] | ||
* [[mediawikiwiki:Manual:Upgrading#Command line|Manual:Upgrading -- Command line]] | * [[mediawikiwiki:Manual:Upgrading#Command line|Manual:Upgrading -- Command line]] | ||
: From the command line, or an SSH shell or similar, change to the | : From the command line, or an SSH shell or similar, change to the '''maintenance''' directory and execute the [[mediawikiwiki:Manual:update.php|update script]]: <s><code>$ php update.php</code></s> '''Use this command instead: <code>/usr/local/php53/bin/php update.php</code>''' | ||
:: Full report here: [[pdxww:User:WikiMaster/The_Dingo_Ate_My_Wiki|User:WikiMaster/The_Dingo_Ate_My_Wiki]] | |||
* [[mediawikiwiki:Manual:FAQ#Upgrading|Manual:FAQ#Upgrading]] | * [[mediawikiwiki:Manual:FAQ#Upgrading|Manual:FAQ#Upgrading]] | ||
== | === Read-Only Mode === | ||
The following two examples show the <tt>$wgReadOnly</tt> setting to add to your [[mediawikiwiki:Manual:LocalSettings.php|LocalSettings.php]] file to lock the database while you upgrade. | |||
* [[mediawikiwiki:Manual:$wgReadOnly|Manual:$wgReadOnly]] | |||
* [[mediawikiwiki: | : <code>$wgReadOnly = 'This wiki is currently being upgraded to a newer software version.';</code> | ||
: | * [[mediawikiwiki:Manual:Lock the database|Manual:Lock the database]] | ||
: <code>$wgReadOnly = "We are upgrading MediaWiki, please be patient. This wiki will be back in a few hours.";</code> | |||
: ' | |||
* [[mediawikiwiki: | |||
: | |||
=== | === Logo & Favicon Settings === | ||
* | * [[mediawikiwiki:Manual:FAQ#How_do_I_change_the_logo.3F|How do I change the logo?]] | ||
* [[mediawikiwiki:Manual:FAQ#How_do_I_change_the_icon_in_the_browser.27s_address_line_.28favicon.29.3F|How do I change the icon in the browser's address line (favicon)?]] | |||
=== | == Using Git == | ||
; Git downloads | |||
You can download code directly via Git from the MediaWiki source code repository (browse code) or download a snapshot. To get the latest version of an extension, for instance, just clone the git master. | |||
For example, if you have shell access to your server, you may do this to download the Validator extension: | |||
cd extensions | |||
git clone https://gerrit.wikimedia.org/r/p/mediawiki/extensions/Validator.git | |||
; Wikimedia Projects on Git | |||
* [ | * [https://gerrit.wikimedia.org/r/#/admin/projects/ Projects] - Big list of MediaWiki extensions and other Wikimedia project available for download from Git repository. | ||
* [ | ; Help Resources | ||
: | * [[mediawikiwiki:Extension:Validator#Git_downloads|Git downloads]] | ||
: An example of downloading [[mediawikiwiki:Extension:Validator|Validator]] using Git. | |||
* [[mediawikiwiki:Download from Git|Download from Git]] | |||
: [[mediawikiwiki:Download from Git#Using_Git_to_download_MediaWiki|Using Git to download MediaWiki]] | |||
* [[mediawikiwiki:Template:WikimediaGitCheckout|Template:WikimediaGitCheckout]] | |||
; [[dreamhost:Git|Git]] Check DreamHost VPS | |||
: Instructions here: [[dreamhost:Git#Pre-installed_git|Pre-installed git]] | |||
Last login: Sat Jun 16 07:47:42 2012 from 97.115.118.134 | |||
[ps11244]$ which git | |||
/usr/bin/git | |||
[ps11244]$ git --version | |||
: | git version 1.7.1.1 | ||
[ps11244]$ | |||
=== [http://www.linuxreaders.com/2011/02/04/how-to-patch-mediawiki-to-latest-version/ How to Patch MediaWiki to latest version] === | === [http://www.linuxreaders.com/2011/02/04/how-to-patch-mediawiki-to-latest-version/ How to Patch MediaWiki to latest version] === | ||
: Example -- Patch update [http://lists.wikimedia.org/pipermail/mediawiki- | : Example -- Patch update [http://lists.wikimedia.org/pipermail/mediawiki-l/2013-December/042243.html MediaWiki 1.22.0] to [http://www.mediawiki.org/wiki/Release_notes/1.22#MediaWiki_1.22.3 MediaWiki 1.22.3]: | ||
# Download Patch Into Main Directory: <code>wget http:// | # Download Patch Into Main Directory: <code>wget http://releases.wikimedia.org/mediawiki/1.22/mediawiki-1.22.3.patch.gz</code> | ||
# Uncompress File: <code>gunzip mediawiki-1. | # Uncompress File: <code>gunzip mediawiki-1.22.3.patch.gz</code> | ||
# Move Patch To Wiki Directory: <code>mv mediawiki-1. | # Move Patch To Wiki Directory: <code>mv mediawiki-1.22.3.patch /path/to/your/wiki</code> | ||
# Apply Patch: <code>patch -i mediawiki-1. | # Do a Dry Run First: <code>patch -p1 --dry-run < mediawiki-1.22.3.patch</code> | ||
# Remove Patch File: <code>rm -rf mediawiki-1. | # Apply Patch: <code>patch -i mediawiki-1.22.3.patch -p 1</code> | ||
# Remove Patch File: <code>rm -rf mediawiki-1.22.3.patch</code> | |||
;Source<nowiki>:</nowiki> [[mediawikiwiki:Manual:Upgrading#Using_patch|Manual:Upgrading#Using_patch]] | |||
; Unix / Linux / Bash | ; Unix / Linux / Bash |
Latest revision as of 12:58, 2 March 2014
MediaWiki: Upgrading
- BACKUP FIRST! Manual:Backing up a wiki
- Automated MySQL Backup Tool - AutoMySQLBackup
- MySQL dump tool - mysqldump — A Database Backup Program
- MySQL Export: How to backup your MySQL database?
- You can easily create a dump file(export/backup) of a database using the phpMyAdmin tool.
- Consider making the Wiki read-only before creating the backup - see Manual:$wgReadOnly. This makes sure all parts of your backup are consistent (some of your installed extensions may write data nonetheless).
- From the command line, or an SSH shell or similar, change to the maintenance directory and execute the update script:
Use this command instead:$ php update.php
/usr/local/php53/bin/php update.php
- Full report here: User:WikiMaster/The_Dingo_Ate_My_Wiki
Read-Only Mode
The following two examples show the $wgReadOnly setting to add to your LocalSettings.php file to lock the database while you upgrade.
$wgReadOnly = 'This wiki is currently being upgraded to a newer software version.';
$wgReadOnly = "We are upgrading MediaWiki, please be patient. This wiki will be back in a few hours.";
Logo & Favicon Settings
Using Git
- Git downloads
You can download code directly via Git from the MediaWiki source code repository (browse code) or download a snapshot. To get the latest version of an extension, for instance, just clone the git master.
For example, if you have shell access to your server, you may do this to download the Validator extension:
cd extensions git clone https://gerrit.wikimedia.org/r/p/mediawiki/extensions/Validator.git
- Wikimedia Projects on Git
- Projects - Big list of MediaWiki extensions and other Wikimedia project available for download from Git repository.
- Help Resources
- An example of downloading Validator using Git.
- Git Check DreamHost VPS
- Instructions here: Pre-installed git
Last login: Sat Jun 16 07:47:42 2012 from 97.115.118.134 [ps11244]$ which git /usr/bin/git [ps11244]$ git --version git version 1.7.1.1 [ps11244]$
How to Patch MediaWiki to latest version
- Example -- Patch update MediaWiki 1.22.0 to MediaWiki 1.22.3:
- Download Patch Into Main Directory:
wget http://releases.wikimedia.org/mediawiki/1.22/mediawiki-1.22.3.patch.gz
- Uncompress File:
gunzip mediawiki-1.22.3.patch.gz
- Move Patch To Wiki Directory:
mv mediawiki-1.22.3.patch /path/to/your/wiki
- Do a Dry Run First:
patch -p1 --dry-run < mediawiki-1.22.3.patch
- Apply Patch:
patch -i mediawiki-1.22.3.patch -p 1
- Remove Patch File:
rm -rf mediawiki-1.22.3.patch
- Source: Manual:Upgrading#Using_patch
- Unix / Linux / Bash
Performance Tuning
- Manual:Performance tuning
- Memcached (DreamHost Wiki)
- memcached + WordPress + DreamHost Shared Hosting
- Long-winded tutorial showing how to set up memcached on DH VPS and use it for domains hosted on DH shared servers.