[Mediawiki-l] backup advice wanted

Christensen, Courtney ChristensenC at BATTELLE.ORG
Mon Jun 23 14:25:26 UTC 2008

Hi Jim,

We routinely use mysqldump on live wikis.  The only consideration is,
"Is content likely to change while the dump is happening?"  So you could
lock the wiki for editing while you dump if you want.  Our largest wikis
seem to take 30 minutes to dump at most.  But then our largest aren't
very large, about ten thousand pages.

Does that help? 

PS.  Don't forget to back up your uploads.

-----Original Message-----
From: mediawiki-l-bounces at lists.wikimedia.org
[mailto:mediawiki-l-bounces at lists.wikimedia.org] On Behalf Of Jim Hu
Sent: Friday, June 13, 2008 2:51 AM
To: MediaWiki announcements and site admin list
Subject: [Mediawiki-l] backup advice wanted

Hi all,

Having learned the hard way that just doing Retrospect filesystem  
backups does not always work on the database... I'm looking for advice  
on how to do backups for our public wikis to minimize downtime when  
we're doing server maintenance.

I've looked at the docs at:

and I'm still a bit confused. Assuming that I'll be using mysqldump...  
do I need to take the wiki offline during the dump process (the  
discussion of mysqldump vs mysqlhotcopy seems to be inconsistent with  
what's at the mysql.com website wrt using hotcopy with InnoDB  
tables)?  Are there any tips people can share?

This came up during a migration of /usr/local/mysql and the apache  
root directory to a new set of disks.  I had backed everything up to  
another set of disks (actually this was temporarily using our dev  
server as a firewire drive).  I pointed usr/local and apache root to  
the backups in the hope that I could keep the wikis online while we  
replaced the main disks on the production server. The plan was to keep  
this running while we set up the new disks and then copy data back to  
the new disks, change the symlinks for /usr/local etc to the new  
places, and restart mysql and apache.  While this is going on, I've  
disabled editing on the backup copy, but users should be able to view/ 
browse/search.    But mysql was very unhappy and wouldn't run from the  
backups.  I ended up deleting all of the files from the backup copy of  
the mysql data directory and rebuilding all the databases in the  
backup from an SQL dump, with apache turned off for several hours.

I feel like there has to be a better way, even with our small operation.



Jim Hu
Associate Professor
Dept. of Biochemistry and Biophysics
2128 TAMU
Texas A&M Univ.
College Station, TX 77843-2128

MediaWiki-l mailing list
MediaWiki-l at lists.wikimedia.org

More information about the MediaWiki-l mailing list