Introduction

As explained in Chapter 6Binary Logging, replication enables data from one MySQL database server (the master) to be copied to one or more MySQL database servers (the slaves). Replication is asynchronous by default; slaves do not need to be permanently  connected  to receive updates from the master. You can configure to replicate all databases, selected databases, or even selected tables within a database.

In this chapter, you will learn how to set up traditional replication; replicate selected databases and tables; and set up multi-source replication, chain replication, delayed replication, and semi-synchronous replication.

On a high level, replication works like this: all DDL and DML statements executed on a server (master ...

Get MySQL 8 Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.