<p>Error 1779 appears when GTID_MODE is set to ON or UPGRADE_STEP_2 while ENFORCE_GTID_CONSISTENCY is disabled.</p>
<p>MySQL Error 1779 ER_GTID_MODE_2_OR_3_REQUIRES_ENFORCE_GTID_CONSISTENCY_ON means GTID mode cannot be enabled until ENFORCE_GTID_CONSISTENCY is set to ON. Turn on ENFORCE_GTID_CONSISTENCY globally, then retry the GTID_MODE change to resolve the issue.</p>
@@GLOBAL.GTID_MODE = ON or UPGRADE_STEP_2 requires
Error 1779 fires when a session tries to switch @@GLOBAL.GTID_MODE to ON, ON_PERMISSIVE, ON_ENFORCED or UPGRADE_STEP_2 without first enabling @@GLOBAL.ENFORCE_GTID_CONSISTENCY. MySQL blocks the change because inconsistent transactions would break global transaction ID integrity.
The error exists in MySQL 5.6 and 5.7 up to 5.7.5. Later versions removed it but still demand GTID consistency before activating GTID mode, returning a different message if the guard condition is unmet.
GTID-based replication assumes every transaction can be safely logged in a GTID-compatible format. Statements that use non-deterministic or unsafe functions break this assumption. ENFORCE_GTID_CONSISTENCY forces the server to reject unsafe statements, maintaining a clean binary log for replicas.
Without this protection, turning GTID on could corrupt replication streams or require complex manual fixes, so MySQL blocks the mode change and raises Error 1779.
Attempting SET GLOBAL GTID_MODE = ON while ENFORCE_GTID_CONSISTENCY is OFF.
Running mysql_upgrade with --upgrade-step=2 on older 5.6 installations where consistency is still disabled.
Automated deployment scripts that toggle GTID_MODE but forget the prerequisite consistency flag.
Mistaking version behavior after 5.7.5, assuming the requirement disappeared entirely.
Error 1776 ER_GTID_MODE_REQUIRES_BINLOG - Raised when binary logging is off while enabling GTID.
Error 1777 ER_CANT_SET_GTID_MODE - Appears if GTID_MODE is changed while replication threads still run.
Error 1780 ER_CANT_CHANGE_GTID_NEXT - Signals that GTID_NEXT cannot be altered in the current context.
Error 1840 ER_GTID_UNSAFE_CREATE_DROP_TEMP_TABLE - Warns about temp table statements unsafe for GTID.
No. Disabling it while GTID_MODE is ON risks replication breakage and is unsupported.
Not under the same code. Newer versions still refuse the change but issue a different error message.
ON_PERMISSIVE lets existing anonymous transactions finish while new transactions get GTIDs, reducing downtime.
Galaxy alerts you to unsafe statements and suggests the correct flag sequence in its SQL editor, preventing Error 1779 during migrations.