Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Transfering MySQL data from one machine to another

Status
Not open for further replies.

JohnLewis25

Programmer
Joined
Nov 26, 2002
Messages
7
Location
GB
What is the simplest way to transfer a complete MySQL database from one machine to another?
 
I would use mysqldump for this. It will backup all tables in a database.

from the unix/linux propmt(not in mysql):

mysqldump -u username -p database > backup.sql

On the second machine first create the database where you want the tables then:

mysql -u username -p database < backup.sql


Mike
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top