I have a local MySQL databases and I want to deploy it on the remote server.
There is some tool in PhpMyAdmin to synchronize local and remote databases, however is very slow if you have large databases, as in my case.
Is there a better and a f开发者_如何学JAVAaster way ? Such as shell through ssh, or something else ?
Fond a solution:
mysqldump -u my_local_db_username --password=my_local_db_password --host=localhost -C my_local_db_name | ssh user@www.my_domain.com "mysql -u my_remote_db_username --password=my_remote_db_password my_remote_db_name"
source: here
精彩评论