GitHub

The check_mysql_query Plugin

check_mysql_query v2.2.git (monitoring-plugins 2.2)
Copyright (c) 1999-2007 Monitoring Plugins Development Team
    <devel@monitoring-plugins.org>

This program checks a query result against threshold levels

Usage:
 check_mysql_query -q SQL_query [-w warn] [-c crit] [-H host] [-P port] [-s socket]
       [-d database] [-u user] [-p password] [-f optfile] [-g group]

Options:
 -h, --help
    Print detailed help screen
 -V, --version
    Print version information
 --extra-opts=[section][@file]
    Read options from an ini file. See
    https://www.monitoring-plugins.org/doc/extra-opts.html
    for usage and examples.
 -q, --query=STRING
    SQL query to run. Only first column in first row will be read
 -w, --warning=RANGE
    Warning range (format: start:end). Alert if outside this range
 -c, --critical=RANGE
    Critical range
 -H, --hostname=ADDRESS
    Host name, IP Address, or unix socket (must be an absolute path)
 -P, --port=INTEGER
    Port number (default: 3306)
 -s, --socket=STRING
    Use the specified socket (has no effect if -H is used)
 -d, --database=STRING
    Database to check
 -f, --file=STRING
    Read from the specified client options file
 -g, --group=STRING
    Use a client options group
 -u, --username=STRING
    Username to login with
 -p, --password=STRING
    Password to login with
    ==> IMPORTANT: THIS FORM OF AUTHENTICATION IS NOT SECURE!!! <==
    Your clear-text password could be visible as a process table entry

 A query is required. The result from the query should be numeric.
 For extra security, create a user with minimal access.

Notes:
 You must specify -p with an empty string to force an empty password,
 overriding any my.cnf settings.

Send email to help@monitoring-plugins.org if you have questions regarding
use of this software. To submit patches or suggest improvements, send email
to devel@monitoring-plugins.org