pmp-check-mysql-processlist - Alert when MySQL processlist has dangerous patterns.
Usage: pmp-check-mysql-processlist [OPTIONS] Options: -C CHECK What to alert on; default states_count. Other options: max_user_conn. -c CRIT Critical threshold; default varies. --defaults-file FILE Only read mysql options from the given file. Defaults to /etc/nagios/mysql.cnf if it exists. -H HOST MySQL hostname. -l USER MySQL username. -L LOGIN-PATH Use login-path to access MySQL (with MySQL client 5.6). -p PASS MySQL password. -P PORT MySQL port. -S SOCKET MySQL socket file. -w WARN Warning threshold; default varies. --help Print help and exit. --version Print version and exit. Options must be given as --option value, not --option=value or -Ovalue. Use perldoc to read embedded documentation with more details.
This Nagios plugin examines MySQL processlist in several ways, depending on the value of the -C option:
Alerts when there are too many processes in various states. The list of checks is as follows:
Unauthenticated users appear when DNS resolution is slow, and can be a warning sign of DNS performance problems that could cause a sudden denial of service to the server.
Locked processes are the signature of MyISAM tables, but can also appear for other reasons.
Too many processes copying to various kinds of temporary tables at one time is a typical symptom of a storm of poorly optimized queries.
Too many processes in the “statistics” state is a signature of InnoDB concurrency problems causing query execution plan generation to take too long.
The thresholds should be given as count. The default critical level is 32, and warning is 16.
Alerts when @@max_user_connections is configured on MySQL and any user reaches this limit. The output of this check will display the user with maximum connections consumed, its count and percentage of the actual limit.
The thresholds should be given as percentage. The default critical level is 95, and warning is 90.
# /usr/lib64/nagios/plugins/pmp-check-mysql-processlist OK 0 unauthenticated, 0 locked, 0 copy to table, 0 statistics | processes=0;16;32;0;
# /usr/lib64/nagios/plugins/pmp-check-mysql-processlist -C max_user_conn OK User with max connections: myappuser (70) = 2% | max_user_conn=2;90;95;0;100
This plugin executes the following commands against MySQL:
This plugin executes no UNIX commands that may need special privileges.
Percona Monitoring Plugins pmp-check-mysql-processlist 1.1.6
For general inquiries, please send us your question and someone will contact you.