1、mysqldump -h host -u user -p dbname>bak.sql

备注:host即原服务器的ip地址,这里有一个前提,就是要将原服务器的mysql设置成远程可连接。

2、然后直接采用:

mysql -u user -p  dbname<bak.sql

相关文章: