Database replication is a process of synchronization in which data added to one database is automatically copied to the other. Replication should not be confused with clustering, as they serve different purposes: cluster databases are made of several self-sufficient nodes, each of which can act as a standalone server, while replication configuration suggests that each server makes its own part of the work.
There are two main methods of database replication: statement-based replication (SBR) and row-based replication (RBR). Both of them suggest that you start with identical contents of your databases and enable logging on the Master Server. In statement-based replication, the system saves all client queries that somehow modify the Master database and then issues the same queries to Slave databases. Row-based replication tracks changes on row level: whenever a client application adds or modifies a row in a table of the Master database, the same row is added or modified in the Slave database.
Since replication expects Master and Slave databases to be identical, you need to synchronize their contents before enabling it. This can be done with Handy Backup, which features a number of plug-ins designed for backup and recovery of different database management systems. If your applications are based on MySQL, please see MySQL Replication.
Master-to-Master Database Replication
Besides Master-to-Slave database replication, there is also a Master-to-Master scheme which is more tricky. In this configuration, each server acts as a Master and a Slave at the same time. This approach is more complicated in setup and maintenance, but provides faster database recovery in case of disaster.
Master-to-Master replication is not the same thing as clustering, because it doesn’t expect the servers to share one configuration. A target use for using this type of configuration is geographical distribution of the database.
In the following video tutorial you can learn how to back up and restore MySQL databases with Handy Backup.
Note: Instructions in this video suggest that you already have Handy Backup installed on your computer. If you still haven’t done so, don’t hesitate to download it.
Database Replication and Backups
Another common use for database replication is backing up. The matter is that exporting all data from a database may slow down the server so much that it will effectively hang. The most effective solution for it is setting up a Slave replication server that will automatically receive all latest updates, and use it for backup purposes. If you are using MySQL DBMS, you can read more at the MySQL Backup feature page.
Version 8.4.2, built on September 19, 2022
Term of the Day
Backup Software Glossary
Current glossary explains various terms that you may come across while working with Handy Backup or other backup software.
Handy Backup is a backup utility for Windows Servers and PCs that is famous for its flexibility and ease of use.
The glossary contains 140 terms. The current section Databases contains 17 terms.
Other “Databases” Terms