3118
MySQLWARNINGNotableReplicationHIGH confidence

gtid_executed was changed

Production Risk

Medium — incorrect gtid_executed can cause replication to skip or replay transactions.

What this means

The gtid_executed system variable was changed, which happens when gtid_purged is updated. This warning informs that gtid_executed has been recalculated.

Why it happens
  1. 1SET @@GLOBAL.gtid_purged caused gtid_executed to be recalculated.
How to reproduce
trigger — this will error
trigger — this will error
SET @@GLOBAL.gtid_purged = 'server-uuid:1-100';

expected output

Warning (Code 3118): The transaction owned gtid_executed was changed.

Fix

Verify gtid_executed reflects the expected state

Verify gtid_executed reflects the expected state
SELECT @@GLOBAL.gtid_executed;

Why this works

Confirms gtid_executed is consistent with gtid_purged.

What not to do

Sources
Official documentation ↗

MySQL 8.0 — 3118 ER_GTID_EXECUTED_WAS_CHANGED2

Content generated with AI assistance and reviewed for accuracy. Found an error? hello@errcodes.dev

← All MySQL errors