Not the answer you need?
Register and ask your own question!

pt-table-checksum writes statements to binlog, creating storm of slave errors

erickerick EntrantInactive User Role Beginner
I'm curious why pt-table-checksum does not set
SET sql_log_bin = 0; I just ran pt-table-checksum on a machine, and it wrote a massive amount of `percona` database REPLACE statements to the binlog. Those statements do not necessarily execute successfully on the slave server. By default I have the slave replicating all databases, and the replica is inundated with slave errors due to this. I can skip slaving of the `percona` database to catch up my slave server, but I have to restart MySQL service to do so.. I don't have that luxury in our production environment; I don't feel it is safe to run this utility on any other machine we have here. Is there an option I have missed? It seems odd the default behavior of the utility isn't safe. Is there a benefit to allowing the percona.checksums information slave to another server when running the utility? thanks!


  • przemekprzemek Percona Support Engineer Percona Staff Role
    Hi Erick,

    The tool in order to identify data differences on the slave has to execute the checksum statements on the slave. This is why it logs them in STATEMENT format, which may raise those errors in certain log verbosity mode.
    This does not mean the tool is not safe, it just has to make independent calculations on the slave, otherwise it would be unable to do the job.
    And, the tool does the comparison via replication channel to be consistent.
Sign In or Register to comment.

MySQL, InnoDB, MariaDB and MongoDB are trademarks of their respective owners.
Copyright ©2005 - 2020 Percona LLC. All rights reserved.