Error "handle a potential duplicate event" occurs when enabling GTID for DM Relay synchronization; disabling GTID allows relay to function normally

Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.

Original topic: DM Relay 同步 开启Gtid时报错handle a potential duplicate event,关闭Gtid开启relay正常

| username: TiDBer_FIhl7zln

【TiDB Usage Environment】Production Environment
【TiDB Version】V7.5.0
【Reproduction Path】Data source enabled Gtid, enabled relay, relay synchronization error handle a potential duplicate event
【Encountered Problem: Problem Phenomenon and Impact】handle a potential duplicate event error code 30029
【Resource Configuration】Go to TiDB Dashboard - Cluster Info - Hosts and take a screenshot of this page
【Attachment: Screenshot/Log/Monitoring】


I tried to disable gtid and then enable relay synchronization, which worked fine, but the cloud service I use has master-slave switchovers.

| username: redgame | Original post link

Check if there are duplicate GTIDs in the data source.