1、要求:
(1)必须是5.7.6版本以上的mysql
(2)GTID状态为OFF
2、开启步骤:
(1):SET GLOBAL ENFORCE_GTID_CONSISTENCY = ‘WARN‘;
(2):SET GLOBAL ENFORCE_GTID_CONSISTENCY = ‘ON‘;
(3):SET GLOBAL GTID_MODE = ‘OFF_PERMISSIVE‘;
(4):SET GLOBAL GTID_MODE = ‘ON_PERMISSIVE‘;
(5):SET GLOBAL GTID_MODE = ‘ON‘;
3、要永久启用,在my.cnf配置文件中添加参数:
gtid-mode=ON
enforce-gtid-consistency
原文地址:https://www.cnblogs.com/magmell/p/9223556.html
时间: 2024-11-05 20:49:01