Posted on 1 Comment

Tracking MySQL replication lag

I sometimes encounter the issue where a replication slave is behind the master, while happily connected and in state of “waiting for binlog event”. Clearly it somehow didn’t get the memo that new stuff was available. I know others have seen this too, but for lack of reproducibility it’s not yet a bug report.
Mark Barger of ANYwebcam has been kind enough to tweak a script so Nagios can alert on this problem, see the Nagios Scripts page in the Resources/Tools section of the OQ website. See the page itself for further details on monitoring and dealing with the problem.

Tracking MySQL replication status in general is important anyway, as basically a master doesn’t “care” whether a slave is connected or not (the system is slave driven) and a slave can quite validly not be connected or replicating at any point in time (stopped to take a backup snapshot, do some big reporting on this slave, etc).

Posted on 1 Comment

Comments are closed.