Giuseppe Maxia <g.maxia@gmail.com> writes:
> I am setting up multi-source replication with four nodes, where nodes
> 1, 2, and 3 are masters and node 4 is the slave of the first 3. The
> slave is *active*, meaning that it has a binary log and runs
> transactions of its own.
> Got fatal error 1236 from master when reading data from binary log:
> 'Error: connecting slave requested to start from GTID 0-104-1, which
> is not in the master's binlog. Since the master's binlog contains
> GTIDs with higher sequence numbers, it probably means that the slave
> has diverged due to executing extra erroneous transactions'
>
> I get the same result if I use 'slave_pos' instead of 'current_pos'.
You need to set gtid_domain_id different on each server:
https://mariadb.com/kb/en/mariadb/global-transaction-id/#use-with-multi-source-replication-and-other-multi-master-setups
This way, your slave's GTID position can be multi-dimensional, effectively
tracking the position in each server individually, eg:
1-101-50,2-102-100,3-103-90,4-104-1
From the error it looks like you do not have different gtid_domain_id
configured, but else do ask again if you still have problems.
Hope this helps,
- Kristian.