phpMyAdmin Print

  • 31

Backing Up Your MySQL Database With phpMyAdmin

If your web site is using WordPress, Joomla, Drupal, OpenCart, or any of the many CMS, e-commerce and vertical market applications available, then your web site is using a MySQL database. Any responsible web site owner knows to back up their web site files regularly, but what about your database? Backing up your MySQL database is important and should be a part of your regular site maintenance routine.

When should I back up my MySQL database?
  • Back up your database before you upgrade WordPress, Joomla, or whatever application your web site happens to be using.
  • If you bring in a new developer, webmaster, etc… to work on your web site, make a database backup before they make any changes. 

To access phpMyAdmin:


1. In your browser, go to https://yourdomain.com/M3phpmyadmin

2. A window will pop up, prompting you to enter the username and password of the database you want to access. Note: In WordPress, this information can be found in the wp-config.php file. In Joomla, it can be found in the configuration.php file.

3. Once logged in, you will see something like the screenshot below. In the left column you should see the name of your database. The name of this database is LV4Q1Dhp but yours will be different. Note: You may also see a database named ‘information_schema’. Don’t make any changes to this database.



4. Click on the name of your database in the left column and then click on the EXPORT tab, indicated by the red arrow in the screenshot below:



5. Now you need to specify your export parameters:

-Under Export Method, select Custom.
-Under Table(s), click the Select All link and make sure everything in the box is highlighted.
-Under Output, select Save output to a file. If your database is very large, you may want to select a Compression method.
-Under Format, select SQL.
-All of the other settings can be left alone. Click the Go button at the bottom of the page. Your database file will start to download.

Congratulations! You have just successfully backed up your MySQL database using phpMyAdmin.

Technical notes:
 This creates an actual backup of your database.  Most databases are updated throughout the day.  If your daily data is important to you with a rapidly updating database, you should make daily backups so you can roll back to a previous day.  Avoid use of plugins such as WordPress backup buddy.  These are very CPU intensive if your database or web sites files are larger than 100 MB.  This backup can not be restored to a working database.  To restore, create a new database via your server's control panel.  Note the name and password.  Import your backup to this new empty database.  Finally, update your script's config to use the new db name and password.  This preserves your old database so you can quickly change your config back if the results aren't as expected.

Warning!  If you are unsure of this advanced process, please consult your web site admin, webmaster, programmer or developer.  Data loss can result from human errors when working with databases, files, backup and restore processes.  If you are training or otherwise learning, its best to practice on a development test site first!

Was this answer helpful?

« Back