Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to keep two MySQL databases in sync?

Is there a way to keep two databases in sync? I have a client who's running WordPress with MySQL. Is there a way to take a copy of the database the current state, and use it for a development server, and then when the dev changes are done push it back to the live site?

The client might make changes to the live site while I'll be working on the dev version, and wondering if there will any merge conflicts.

If I import the updated database via phpmyadmin, will it only update with only the newest changes or overwrite everything?

like image 738
Alex Avatar asked Jun 17 '13 01:06

Alex


People also ask

How do you sync two databases in MySQL workbench?

To start the wizard, open a model and select Database and then Synchronize With Any Source from the main menu. The steps are similar to the Synchronize Model wizard, but with additional options to create SQL script files, use SQL script files, or both.

What is MySQL synchronization?

MySQL synchronization is a process of making two MySQL databases having identical contents. It's a general idea that is realized differently in clustering, replication and other applications. Handy Backup synchronizes MySQL tables via backup and recovery.


1 Answers

Here's a quick reference of MySQL Replication by @Mark Baker or you can use MySQL Workbench Synchronization.

like image 73
Mark Avatar answered Oct 03 '22 22:10

Mark