Difference between revisions of "Wikibackup"

From Teknologisk videncenter
Jump to: navigation, search
m
m
Line 11: Line 11:
 
mysqldump -u USERNAME -pPASSWORD --default-character-set=latin1 wikidb -c > /home/backup/wikidb120209.dump
 
mysqldump -u USERNAME -pPASSWORD --default-character-set=latin1 wikidb -c > /home/backup/wikidb120209.dump
 
</pre>
 
</pre>
 +
[[category:SQL]][[category:mediawiki]]

Revision as of 13:56, 23 February 2009

Backup of this wiki

Locking the database

During backup, the database will be locked using the $wgReadOnly variable in LocalSettings.php

$wgReadOnly = '<b>Backup operation in progress.</b> Please wait a few minutes.';

mysqldump

example

mysqldump -u USERNAME -pPASSWORD --default-character-set=latin1 wikidb -c > /home/backup/wikidb120209.dump