Documentation Home
MySQL 8.4 Reference Manual
Related Documentation Download this Manual
PDF (US Ltr) - 39.8Mb
PDF (A4) - 39.9Mb
Man Pages (TGZ) - 257.9Kb
Man Pages (Zip) - 364.9Kb
Info (Gzip) - 4.0Mb
Info (Zip) - 4.0Mb


MySQL 8.4 Reference Manual  /  Group Replication

Chapter 20 组复制

Table of Contents

20.1 组复制 Background
20.1.1 复制 Technologies
20.1.2 组复制 Use Cases
20.1.3 多主模式和单主模式
20.1.4 组复制 Services
20.1.5 组复制 Plugin Architecture
20.2 入门
20.2.1 Deploying 组复制 in Single-Primary Mode
20.2.2 Deploying 组复制 Locally
20.3 要求和限制
20.3.1 组复制 Requirements
20.3.2 组复制 Limitations
20.4 Monitoring 组复制
20.4.1 GTIDs and 组复制
20.4.2 组复制 Server States
20.4.3 replication_group_members 表
20.4.4 replication_group_member_stats 表
20.5 组复制 Operations
20.5.1 配置在线组
20.5.2 重启组
20.5.3 事务一致性保证
20.5.4 分布式恢复
20.5.5 支持 IPv6 和混合 IPv6 和 IPv4 组
20.5.6 Using MySQL Enterprise Backup with 组复制
20.6 组复制 Security
20.6.1 Communication Stack for Connection 安全性 Management
20.6.2 Securing Group Communication Connections with Secure Socket Layer (SSL)
20.6.3 Securing 分布式恢复 Connections
20.6.4 组复制 IP Address Permissions
20.7 组复制 Performance and Troubleshooting
20.7.1 微调组通信线程
20.7.2 流控制
20.7.3 单一共识领导者
20.7.4 消息压缩
20.7.5 消息碎片
20.7.6 XCom 缓存管理
20.7.7 Responses to Failure Detection and Network 分区
20.7.8 处理网络分区和仲裁丢失
20.7.9 Monitoring 组复制 Memory Usage with Performance Schema Memory Instrumentation
20.8 Upgrading 组复制
20.8.1 在组中组合不同的成员版本
20.8.2 组复制 Offline Upgrade
20.8.3 组复制 Online Upgrade
20.9 组复制 Variables
20.9.1 组复制 System Variables
20.9.2 组复制 Status Variables
20.10 常见问题

This chapter explains Group Replication in MySQL 8.4, and how to install, configure and monitor groups. MySQL Group Replication enables you to create elastic, highly-available, fault-tolerant replication topologies.

Groups can operate in a single-primary mode with automatic primary election, where only one server accepts updates at a time. Alternatively, groups can be deployed in multi-primary mode, where all servers can accept updates, even if they are issued concurrently.

There is a built-in group membership service that keeps the view of the group consistent and available for all servers at any given point in time. Servers can leave and join the group and the view is updated accordingly. Sometimes servers can leave the group unexpectedly, in which case the failure detection mechanism detects this and notifies the group that the view has changed. This is all automatic.

Group Replication guarantees that the database service is continuously available. However, it is important to understand that if one of the group members becomes unavailable, the clients connected to that group member must be redirected, or failed over, to a different server in the group, using a connector, load balancer, router, or some form of middleware. Group Replication does not have an inbuilt method to do this. For example, see MySQL Router 8.4.

Group Replication is provided as a plugin to MySQL Server. You can follow the instructions in this chapter to configure the plugin on each of the server instances that you want in the group, start up the group, and monitor and administer the group. An alternative way to deploy a group of MySQL server instances is by using InnoDB Cluster.

Tip

To deploy multiple instances of MySQL, you can use InnoDB Cluster which enables you to easily administer a group of MySQL server instances in MySQL Shell. InnoDB Cluster wraps MySQL Group Replication in a programmatic environment that enables you easily deploy a cluster of MySQL instances to achieve high availability. In addition, InnoDB Cluster interfaces seamlessly with MySQL Router, which enables your applications to connect to the cluster without writing your own failover process. For similar use cases that do not require high availability, however, you can use InnoDB ReplicaSet. Installation instructions for MySQL Shell can be found here.

The chapter is structured as follows: