How do I move my MySQL Databases from old Host?

This can be used to back up a database or to move database information from one server to another.

1. Export A MySQL Database

This example shows you how to export a database. It is a good idea to export your data often as a backup.

# mysqldump username -ppassword database_name > FILE.sql



Replace username, password and database_name with your MySQL username, password and database name.

File FILE.sql now holds a backup of your database, download it to your computer.

2. Import A MySQL Database

Here, we import a database. Use this to restore data from a backup or to import from another MySQL server.

Start by uploading the FILE.sql file to the server where you will be running this command.

# mysql -u username -ppassword database_name < FILE.sql

Replace the parts in bold with your own information.

This powerful, easy to use command has many uses. Let's say you wanted to switch to HostNine. Simply export your data on the old provider's server and import it on your account with the new host.

Was this answer helpful?

 Print this Article

Also Read

Do you allow adult, warez or other illicit sites or content?

No. Please see our Terms of Service located at   http://www.labelhosting.com/terms.php for...

My order was marked as Fraud and invoice automatically cancelled

If you have just signed up for service and received a MaxMind Fraud error, your account is marked...

I wish to operate two or more websites that have their separate control panel?

In order to have a separate control panel access for each of your hosted domains/websites, we...

Do you offer an uptime guarantee?

Label Hosting guarantees your website to be online at least 99.9% of the time. If we fail to...

How long does it take to get my website online?

New account activation is completed within 24 hours follow receipt of your initial payment. ...

Powered by WHMCompleteSolution