We had master to master replication with two node nodes A & B, both are in virtual environment. Initially there was an outage (diskspace issue) in node A and stopped replication. Application level traffic has been diverted to node B and relocated the node A data store and made available of space.
Node A has started successfully & up.Coming Coming to the replication has started and got andan error in node B while syncing with node A and bin log in node bB got corrupted. What is theThe root cause is still a mystery. But analyzing the logs could found some duplicate entries and below is the error log info :
[ERROR] Error reading packet from server: Client requested master to start replication from impossible position ( server_errno=1236).[ERROR] Slave I/O: Got fatal error 1236 from master when reading data from binary log: 'Client requested master to start replication from impossible position', Error_code: 1236 111014 20:25:48 [Note] Slave I/O thread exiting, read up to log 'mysql-bin.001067', position 183468345.
[ERROR] Error reading packet from server: Client requested master to start replication from impossible position ( server_errno=1236).
[ERROR] Slave I/O: Got fatal error 1236 from master when reading data from binary log: 'Client requested master to start replication from impossible position', Error_code: 1236
111014 20:25:48 [Note] Slave I/O thread exiting, read up to log 'mysql-bin.001067', position 183468345.
How todo we handle the replication atin this situation ? Can we skip the current bin-log and start the replication with the next available bin - loglog and its posistionposition. isIs it a good idea to sync node B with node A :
CHANGE MASTER TO MASTER_HOST='XX.XX.XXX.XXX', MASTER_USER='replicate', MASTER_PASSWORD='slave', MASTER_PORT=3306, MASTER_LOG_FILE='mysql-bin.001025', MASTER_LOG_POS=4, MASTER_CONNECT_RETRY=10;
CHANGE MASTER TO
MASTER_HOST='XX.XX.XXX.XXX',
MASTER_USER='replicate',
MASTER_PASSWORD='slave',
MASTER_PORT=3306,
MASTER_LOG_FILE='mysql-bin.001025',
MASTER_LOG_POS=4,
MASTER_CONNECT_RETRY=10;
The main reason iI am posing this scenario is, that iI don't want to restore the DB and build it from scratch,where where DB backup is around 80 GB in node B. How can iI repair the replication.?