check_rabbitmq_shovels1p
Nagios plugin to check that all shovels of the given rabbitmq host are running
Usage
check_rabbitmq_shovels --hostname
<host>
check_rabbitmq_shovels {--help | --man | --version}
Options
Program options
-
-H, --hostname string -
Specify the RabbitMQ host to query. Defaults to
"localhost".
-
-P, --port number -
Specify the port number to query RabbitMQ on. Defaults to 55672.
-
-u, --user, --username string -
Specify the username. Defaults to
"guest".
-
-p, --pass, --password string -
Specify the password. Defaults to
"guest".
-
-t, --timeout duration -
Specify the timeout period in seconds. Defaults to 5.
Help options
-
-?, --usage -
Print a short usage description, then exit.
-
-h, --help -
Print a more detailed help screen, then exit.
-
-V, --version -
Print the program name and version, then exit.
Overview
This program is a Nagios plugin that uses the JSON over HTTP API to check that all shovels of the given RabbitMQ host are running. The default settings match the standard installation of RabbitMQ.
The check returns "OK" if all shovels are running, "WARNING" if one or more shovels are blocked, "CRITICAL" if one or more shovels are terminated.
Examples
With default settings, only the hostname need to be specified:
check_rabbitmq_shovels -H <host>
It prints the global status and the details of the shovels, by decreasing order or criticity:
RABBITMQ_SHOVELS OK - 3 running shovels: klonk zlott swishRABBITMQ_SHOVELS WARNING - 1 blocked shovel: klonk, 2 running shovels: zlott swishRABBITMQ_SHOVELS CRITICAL - 1 terminated shovel: zlott, 1 blocked shovel: klonk, 1 running shovel: swish
In the case of an API error, the program will give an appropriate diagnostic:
RABBITMQ_SHOVELS CRITICAL - API error: 401 UnauthorizedRABBITMQ_SHOVELS CRITICAL - API error: 500 Can't connect to <host>:<port>RABBITMQ_SHOVELS CRITICAL - API error: could not parse JSON: malformed JSON stringRABBITMQ_SHOVELS CRITICAL - API error: empty JSON
Releases
2 releases since Debian 12 (Bookworm); the text changed 1 time.