RabbitMQ monitoring

RabbitMQ offers CLI (command line interface) tools for monitoring. To check if RabbitMQ process is working fine you should issue following command on the server where it runs:

rabbitmq-diagnostics ping

Feedback is given with the exit code of the command above. You can get it's value from environment variable $? with following command

echo $?

Below you can find meaning of the exit codes

Exit code ($?)Meaning
0OK - Works fine
2CRIT - There are some issues with RabbitMQ

RabbitMQ itself opens following ports

5672/TCPData exchange
15672/TCPWWW Administration panel

Both of these ports can be used for checking if the service is still running.

What’s Next