# Mysql



## rbizzell33 (Feb 3, 2010)

I need to move a mysql database to a new server that is running moodle homework portal software. I did mysql dump on the old server. Once I copy the dump file over to the new server how do I extract the dump file into the database? Do I have to create a database with the same name or just extract the database and it will create it


----------



## SirDice (Feb 3, 2010)

http://lmgtfy.com?q=how+to+restore+mysql+dump


----------



## Artefact2 (Feb 3, 2010)

```
mysql -u'USER' -p'PASSWORD'
CREATE DATABASE your_database;
^D

mysql -u'USER' -p'PASSWORD' your_database < your_dump.sql
```

Hope it helps


----------

