Mysql checksum for master-slave replication returning different values, despite being identical

Sunday, July 6, 2014

I've set up a master slave replication in mysql and to make sure that I know if the data starts getting out of sync I created a script that:



  1. Locks both databases on both servers.

  2. Prints the checksums of all the tables to a text file.

  3. Copy's the slave checksum text file to master.

  4. Compares the both files to see if anything is different.


But on some tables I got different checksums. So I downloaded both those tables and created another script to find whats different on them. And Nothing is different! They're identical.


I do have slightly different versions of mysql installed, could this be causing it?



+-------------------------+-----------------------------+
| Variable_name | Value |
+-------------------------+-----------------------------+
| innodb_version | 5.5.34 |
| protocol_version | 10 |
| slave_type_conversions | |
| version | 5.5.34-0ubuntu0.13.04.1-log |
| version_comment | (Ubuntu) |
| version_compile_machine | x86_64 |
| version_compile_os | debian-linux-gnu |
+-------------------------+-----------------------------+

+-------------------------+-----------------------------+
| Variable_name | Value |
+-------------------------+-----------------------------+
| innodb_version | 5.5.37 |
| protocol_version | 10 |
| slave_type_conversions | |
| version | 5.5.37-0ubuntu0.14.04.1-log |
| version_comment | (Ubuntu) |
| version_compile_machine | x86_64 |
| version_compile_os | debian-linux-gnu |
+-------------------------+-----------------------------+


Anyone of you know what could be causing this?







http://ift.tt/1vMJgcu