Difference between revisions of "Backup and restore a database"

From GeeklogWiki
Jump to: navigation, search
 
(Some minor additions and corrections)
 
Line 6: Line 6:
  
 
# Log into your site.
 
# Log into your site.
# In the <b>Admins Only</b> block on the left, click the "DB Backups" link. Any previously created backups will be listed here.
+
# In the [[Admins Block|Admins Only]] block on the left, click the "DB Backups" link. Any previously created backups will be listed here.
 
# Click the "Create New" link.
 
# Click the "Create New" link.
# If you want to store a copy of the backup on your computer, you will need to download it via FTP (or however you access your site to upload and download files). The backups are stored in the backups/ folder.
+
# If you want to store a copy of the backup on your computer, you can click on the name of the backup file to download it. Alternatively, you can download it via FTP (or however you access your site to upload and download files). The backups are stored in the backups/ folder.
 +
 
 +
'''Note:''' The "DB Backups" option is only available when your site is running on MySQL.
  
 
=== Restoring A Database In phpMyAdmin ===
 
=== Restoring A Database In phpMyAdmin ===
  
These instructions are for use with website hosts who provide phpMyAdmin for the administration of databases. Please contact your website host for information on how to access phpMyAdmin (if available) or to determine what is available for you to manage your database.
+
These instructions are for use with website hosts who provide [http://www.phpmyadmin.net/ phpMyAdmin] for the administration of databases. Please contact your website host for information on how to access phpMyAdmin (if available) or to determine what is available for you to manage your database.
  
 
==== Delete your existing database ====
 
==== Delete your existing database ====

Latest revision as of 17:25, 10 May 2009

Intro

It is advisable to create a backup of your database regularly (or after major changes to your site). With these backups, you can restore all of the data on your site.

Creating A Database Backup In Geeklog

  1. Log into your site.
  2. In the Admins Only block on the left, click the "DB Backups" link. Any previously created backups will be listed here.
  3. Click the "Create New" link.
  4. If you want to store a copy of the backup on your computer, you can click on the name of the backup file to download it. Alternatively, you can download it via FTP (or however you access your site to upload and download files). The backups are stored in the backups/ folder.

Note: The "DB Backups" option is only available when your site is running on MySQL.

Restoring A Database In phpMyAdmin

These instructions are for use with website hosts who provide phpMyAdmin for the administration of databases. Please contact your website host for information on how to access phpMyAdmin (if available) or to determine what is available for you to manage your database.

Delete your existing database

Before you can restore your database, you will need to delete the existing one. Before you delete your database, make sure you have created a backup! There is no Undo button.

  1. Log into phpMyAdmin .
  2. Select your database from the dropdown list on the left.
  3. In the main window (the large one on the right), scroll to the bottom and click "Check All".
  4. In the "With selected" dropdown box, select "Drop".
  5. Click the "Yes" button to confirm that you want to drop the tables.

Restore a database

  1. Log into phpMyAdmin if you haven't already.
  2. Select your database from the dropdown list on the left.
  3. Click the "SQL" tab at the top of the main window.
  4. Click the "Browse" button. Find and select your database-backup file.
  5. Click the second "Go" button.