Difference between revisions of "Help:Wiki Backup"

From Mech
Jump to navigationJump to search
m
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
'''LAST BACKUP : 7/7/2006'''
'''LAST BACKUP : BJS 8/11/2006'''


You need to backup two things in order to restore the wiki:
You need to backup two things in order to restore the wiki:
Line 5: Line 5:
* The wiki mysql database
* The wiki mysql database
* The images folder
* The images folder
* The settings files


===Backing up the MySQL Database===
===Backing up the MySQL Database===
Line 15: Line 16:
# Delete the mewiki.sql.gz file from the server.
# Delete the mewiki.sql.gz file from the server.


To restore the wiki database,
===Restoring the MySQL Database===


# Upload the mewiki.sql.gz file to the Hades webserver
# Upload the mewiki.sql.gz file to the Hades webserver
Line 30: Line 31:
# FTP download the file images.tar.gz to a safe place.
# FTP download the file images.tar.gz to a safe place.
# Delete the images.tar.gz file from the server.
# Delete the images.tar.gz file from the server.

===Backing up the Settings Files===

# goto the wiki directory (./wiki)
# Copy the file, LocalSettings.php, to your backup folder
# Copy the folder, external, to your backup folder

To restore,

# copy "LocalSettings.php" and the "external" folder to the wiki directory.
# make sure the "external" folder is chmod 711.

Latest revision as of 10:29, 11 August 2006

LAST BACKUP : BJS 8/11/2006

You need to backup two things in order to restore the wiki:

  • The wiki mysql database
  • The images folder
  • The settings files

Backing up the MySQL Database

  1. Open SSH Secure Shell
  2. Login to the Hades server (see administrator)
  3. Type:
    mysqldump -h localhost -u [USERNAME] -p -B mewiki > mewiki.sql
  4. Zip the database file:
    gzip mewiki.sql
  5. FTP to the directory containing the mewiki.sql.gz file and download to a safe place
  6. Delete the mewiki.sql.gz file from the server.

To restore the wiki database,

  1. Upload the mewiki.sql.gz file to the Hades webserver
  2. Unzip the file:
    gunzip -xf mewiki.sql.gz
  3. Insert the database:
    mysql -h localhost -u [USERNAME] -p mewiki < mewiki.sql
  4. Enter the password for the mysql database
  5. Delete the mewiki.sql from the server.

Backing up the Images Folder

  1. Navigate to the wiki directory (./wiki)
  2. Tar the images folder:
    tar -cf images.tar images
  3. Zip the file:
    gzip images.tar
  4. FTP download the file images.tar.gz to a safe place.
  5. Delete the images.tar.gz file from the server.

Backing up the Settings Files

  1. goto the wiki directory (./wiki)
  2. Copy the file, LocalSettings.php, to your backup folder
  3. Copy the folder, external, to your backup folder

To restore,

  1. copy "LocalSettings.php" and the "external" folder to the wiki directory.
  2. make sure the "external" folder is chmod 711.