8.4 中文镜像

MySQL 8.4 参考手册 · 中文镜像

正文为中文,英文原文默认隐藏。点击任意中文段落即可展开 / 收起对应英文原文。

打开官方英文原文 ↗

译文由机器翻译生成,仅供理解参考;有疑问请以官方英文原文为准。

MySQL 8.4 参考手册 / 20 组复制 / 20.7 组复制性能和故障排除
中文点击中文段落可显示 / 隐藏英文原文本页译文覆盖 100%

20.7 组复制性能与故障排除20.7 Group Replication Performance and Troubleshooting

组复制旨在创建具有内置故障检测和自动恢复功能的容错系统。如果一个成员服务器实例自愿离开或停止与组通信,剩余成员将在彼此之间商定组的重新配置,并在需要时选择新的主节点。被驱逐的成员会自动尝试重新加入组,并通过分布式恢复使其与组保持同步。如果一个组遇到问题,无法联系到大多数成员以达成决策,它会将自己标识为失去法定人数并停止处理事务。组复制还具有内置机制和设置,帮助组适应和管理工作负载及消息大小的变化,并保持在底层系统和网络资源的限制范围内。Group Replication is designed to create fault-tolerant systems with built-in failure detection and automated recovery. If a member server instance leaves voluntarily or stops communicating with the group, the remaining members agree a reconfiguration of the group between themselves, and choose a new primary if needed. Expelled members automatically attempt to rejoin the group, and are brought up to date by distributed recovery. If a group experiences a level of difficulties such that it cannot contact a majority of its members in order to agree on a decision, it identifies itself as having lost quorum and stops processing transactions. Group Replication also has built-in mechanisms and settings to help the group adapt to and manage variations in workload and message size, and stay within the limitations of the underlying system and networking resources.

组复制的系统变量的默认设置旨在最大化组的性能和自主性。本节中的信息旨在帮助您配置复制组,以优化对您特定系统上可能遇到的任何反复问题(例如暂时的网络中断或超出服务器实例资源的工作负载和事务)的自动处理。The default settings for Group Replication’s system variables are designed to maximize a group’s performance and autonomy. The information in this section is to help you configure a replication group to optimize the automatic handling of any recurring issues that you experience on your particular systems, such as transient network outages or workloads and transactions that exceed a server instance’s resources.

如果您发现群组成员被频繁驱逐并重新加入群组,超过了您的预期,这可能是因为群组复制的默认故障检测设置对您的系统过于敏感。在网络较慢或机器较慢、网络中意外短暂中断率较高,或在计划的网络中断期间,可能会出现这种情况。有关通过调整设置来应对这种情况的建议,请参见第 20.7.7 节,“故障检测和网络分区响应”。If you find that group members are being expelled and rejoining the group more frequently than you would like, it is possible that Group Replication’s default failure detection settings are too sensitive for your system. This might be the case on slower networks or machines, networks with a high rate of unexpected transient outages, or during planned network outages. For advice on dealing with that situation by adjusting the settings, see Section 20.7.7, “Responses to Failure Detection and Network Partitioning”.

你通常只需要在 Group Replication 设置中手动干预,当发生一些群组无法自动处理的情况时。需要管理员干预的一些关键问题包括成员处于 ERROR 状态且无法重新加入群组,或者网络分区导致群组失去法定人数。You should only need to intervene manually in a Group Replication setup if something happens that the group cannot deal with automatically. Some key issues that can require administrator intervention are when a member is in ERROR status and cannot rejoin the group, or when a network partition causes the group to lose quorum.