Skip to content

check_mysql - allow until condition on a slave [sf#3351505] #1007

@monitoring-user

Description

@monitoring-user

Submitted by megamaddin on 2011-07-03 16:51:45

Patch against Plugin Version (-V output): check_mysql v1.4.15 (nagios-plugins 1.4.15)
Plugin Name: check_mysql
Example Plugin Commandline: check_mysql -H localhost -S
Tested on operating system: CentOS 5.5
Tested on architecture: AMD64
Tested with compiler: gcc-Version 4.1.2 20080704 (Red Hat 4.1.2-50)

The check_mysql plugin fails with a wrong exit code, if the mysql slave server is started with an UNTIL condition and the sever reaches its desired binlog position. If the binlog position is reached, the slave sql thread stops running, until it's started again, and that is the problem. This patch solves this error by looking if the slave thread is started with an until condition and throws only an error if the Last_Errno variable in mysql is set.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions