At the data center there was electricity outage. And it appears that at that time my replication stopped syncing because it said something like this; "I cannot find the next position. Last proper position was at mysqld-bin.000137 at 1234567890. What is going on?" Then I said "Ok, whatever, just start reading mysqld-bin.000138. It looks like the next file". And now, after an half hour it looks like there is no problem. I mean it replicates.

However I don't know whether there is missing data in my slave. If there is missing data what is going to happen? Eventually will the slave be synchronized if there is lots of deletes, inserts, and updates?

  • 2
    I wouldn't trust this - I would either completely rebuild the slave or use the Percona toolkit to check: percona.com/doc/percona-toolkit/2.2/pt-table-checksum.html – dwjv Oct 2 '15 at 8:32
  • 1
    Its safe to say that your replica is out of sync with the master. By forwarding to mysqld-bin.000138, you skipped every trx between mysqld-bin.000137 at 1234567890 and mysqld-bin.000138. Depending on your workload, that could be a lot of DLLs and DMLs. You have two options: 1. Take a good backup, either shutdown the server and copy the data or use a tool like innobackup / xtrabackup. 2. use tools like Perocna's pt-table-checksum and pt-table-sync to identify which tables are out of sync and then sync them through replication. – Dave Oct 2 '15 at 12:59
  • It happened again. I had to start it from mysqld-bin.000139 now. I've counted (COUNT(ID)) rows in few critical tables and they matched exactly with the replication server. I know it is not very healthy method but at least there is daily backups and I think if there is missing data in the replication, it will throw error in near future. – ilhan Oct 3 '15 at 7:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.