How do I backup my MySQL database?

Backing up your MySQL database can be done in several ways

1. Using the backup tool from the Web Tools section.
2. Using phpMyAdmin web interface.
3. Using command line through shell access.
4. Using MySQL Workbench.

(1) Using our backup tool

Log into your Fast Name Control Panel and click on Web Tools. Click to configure MySQL Databases and click 'Now' under backup database. Save this file to your local machine.

(2) Using phpMyAdmin

Log into your Fast Name Control Panel and click on "MySQL Databases". Click on the "Manage" button for the database that you wish to back up, this will start PhpMyAdmin. From here, go to the "Export" page, then complete the following steps:

1. Select all tables.
2. Select "Structure and data".
3. Select "Add drop table" .
4. Select "Enclose table and field names with backquotes" .
5. Select "Save as file".
6. Click the "Go" button.

You will be prompted to save the dump file on your computer.

(3) Using MySQL command line tools

To use MySQL command line tools, you will need SSH access to be enabled on your hosting account. You can perform backup using the following command:

mysqldump -h servername -u username -p --add-drop-table --create-options --skip-add-locks -e --set-charset --disable-keys -Q databasename > databasedump.sql

To backup and compress your dump file:

mysqldump -h servername -u username -p --add-drop-table --create-options -e --set-charset --skip-add-locks --disable-keys -Q databasename | gzip > databasedump.sql.gz

The commands above will create the dump file in your current directory. You can download this backup file using scp or ftp for your archival purposes. If you perform this command in the public_html directory (or if you move the file into the public_html directory), you will be able to download this file from the web.

(4) You can download MySQL Workbench from http://wb.mysql.com/ - this will allow you to connect to the MySQL process on the server directly and create a local backup of the data.

  • 176 Users Found This Useful
Was this answer helpful?

Related Articles

How can I manage my MySQL database?

Once you have created a database using your Fast Name Control Panel you will be able to manage it...

How can I upload my MySQL database?

There are numerous ways to upload a MySQL database, we would strongly recommend trying methods 2...

How do I connect to MySQL via SSH (telnet)?

You can connect to the server using SSH Telnet, once logged into the system you can access MySQL...

How do I connect to my MySQL database?

A simple php script to open a connection to a database$dbhost = 'localhost';$dbuser = 'db...

What is MySQL?

MySQL is a Relational Database Management System. A relational database adds speed and...

Powered by WHMCompleteSolution