mysqldump backup and restore to remote server

前端 未结 6 709
清酒与你
清酒与你 2020-12-15 08:31

How can i use mysqldump to backup and restore database to a remote server?

Both have root access. I am using putty to perform this.

So far I tried the follo

6条回答
  •  情书的邮戳
    2020-12-15 09:28

    For a single DB, Taking backup from a remote server is :

    mysqldump -u -p -h [database-name] > dump.sql

    Restore is:

    mysql -u -p -h [database-name] < dump.sql

    more details about options of mysqldump are available here: https://dev.mysql.com/doc/refman/8.0/en/mysqldump.html

提交回复
热议问题