xRobot
xRobot

Reputation: 26567

restore backup mysql

I have a backup of my database in mysql of 250MB !!

How can I restore it in a new database on another server ?

Upvotes: 2

Views: 652

Answers (3)

mosg
mosg

Reputation: 12381

Or just use phpMyAdmin for restore porpoise.

Upvotes: 2

Pekka
Pekka

Reputation: 449425

You are providing no detail on what operating system you're on and what kind of backup you have, but the short answer is

mysql -u username -p -h hostname databasename < dumpfile.sql

where dumpfile.sql needs to be a file containing SQL statements, for example produced with mysqldump.

Upvotes: 1

cherouvim
cherouvim

Reputation: 31903

Using:

mysql -u USER -p -h HOST DATABASE < mysqldump.sql

Upvotes: 1

Related Questions