Skip to main content
This page describes what to do in case of an Icinga alert. For more information you could search the govuk-puppet repo for the source of the alert
Last updated: 28 Jun 2022

RabbitMQ: Dead nodes in cluster

This can happen if one of the machines in the cluster is killed by AWS and replaced with a new machine. In this scenario, the cluster is still working, but leaving the dead node will cause problems in future e.g. when we try to reboot the machines to install updates. The check can be found here.

First, check which node is dead:

gds govuk connect -e production ssh aws/rabbitmq "sudo rabbitmqctl cluster_status"

If a node is dead, there will be more “nodes” than “running_nodes”. Once you know the identity of the dead node, you should verify whether the machine still exists:

gds govuk connect -e production ssh aws/jumpbox "govuk_node_list -C rabbitmq"

If the dead node is not in the list, then it can be safely removed from the cluster. To do this, run the following with the dead node:

gds govuk connect -e production ssh aws/rabbitmq "sudo rabbitmqctl forget_cluster_node rabbit@ip-xx-xx-x-xx"

For information about how we use RabbitMQ, see here.