~$ sudo apt-get

Backup mysql database to remote database

by on Apr.09, 2009, under Linux

mysqldump --verbose --opt -u'username' -p'password' 'database' --tables 'table' | grep -v SQL_NOTES | mysql --host='hostname or IP' -u'username' -p'password' 'database'

Input all required information and remove the single quotations.

This specific command does a mySQL dump for a specific table within a database and pipes this output to a remote mySQL database connection.

The ‘grep -v’ was added to parse out SQL_NOTES as sending machine was 4.1.22 and receiver was 5.0.0 and did not like the syntax.


Leave a Reply

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!

Visit our friends!

A few highly recommended friends...