Getting readiness probe failed: dial tcp <IP>:5672 connect: connection refused error in rabbitmq-cluster pods

2,091 views
Skip to first unread message

Aishwarya K

unread,
Feb 10, 2022, 1:29:12 AM2/10/22
to rabbitmq-users
Hi,
I am new to rabbitmq and would appreciate help in the issue I am facing.
I have deployed rabbitmq using the rabbitmq cluster k8s operator on openshift which is hosted on Azure. (This is the guide I referred to deploy the operator-https://www.rabbitmq.com/kubernetes/operator/quickstart-operator.html). PFA rabbitmq-cluster.yaml.

The operator and cluster is up and running, also able to access the management UI on localhost:15672.

But when I describe the pod, it shows the warning of readiness probe failed (image attached readiness probe failed).

Due to this, when I try to run the rabbitmq hello world tutorial (https://www.rabbitmq.com/tutorials/tutorial-one-javascript.html), it fails with the below error as attached (send-app error)

From the management UI, I am able to create new exchange, queue and binding and send & publish msgs.

Kindly take a look and let me know if I am missing anything.

Thanks,
Aishwarya K

PS. apologies if the conversation format is incorrect, pls feel free to correct me and I'll take care from next time. Thank you.

readiness probe failed.JPG
send-app error.JPG
rabbitmq-cluster.yaml.txt

Michal Kuratczyk

unread,
Feb 10, 2022, 5:14:10 AM2/10/22
to rabbitm...@googlegroups.com
Hi,

Can you provide the logs and the output of `rabbitmqctl status` please?

As a side note, large parts of your YAML are unnecessary:
- rabbitmq_management, rabbitmq_peer_discover_k8s and rabbitmq_prometheus are enabled by default (and for federation, using .spec.rabbitmq.additionalPlugins would be better)
- peer discovery is automatically configured as well
- I'm not sure why you need to do anything about the ports either

Best,

--
You received this message because you are subscribed to the Google Groups "rabbitmq-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rabbitmq-user...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/rabbitmq-users/b359aa15-b640-4680-8eb7-f7954741fbe5n%40googlegroups.com.


--
Michał
RabbitMQ team

Aishwarya K

unread,
Feb 10, 2022, 6:11:07 AM2/10/22
to rabbitmq-users
Hi,
PFA output of rabbitmqctl status. 
(couldn't paste the o/p directly due to company policy restrictions hence attaching snapshots).

Also, will remove the unnecessary parts from yaml as per your suggestion.

Thanks & regards,
Aishwarya 

rabbitmqctl status 5.JPG
rabbitmqctl status 1.JPG
rabbitmqctl status 4.JPG
rabbitmqctl status 3.JPG
rabbitmqctl status 2.JPG

Aishwarya K

unread,
Feb 11, 2022, 12:10:43 AM2/11/22
to rabbitmq-users
Hi,

Update- I am now not getting readiness probe failed when I describe the pod. Strangely, It got solved itself.

1. However when I do $oc logs <rabbitmq-cluster pod> it shows the output as attached.

2. Also, if my pod is up and running, shouldn't the port 5672 be up too? It doesn't show up when I run netstat on my openshift cluster.

error- oc pod logs.JPG

Michal Kuratczyk

unread,
Feb 11, 2022, 3:59:12 AM2/11/22
to rabbitm...@googlegroups.com
Hi,

If you see these messages and the readinessProbe is healthy then the port must be open. If you don't see it in netstat output, I guess it's a matter of where/how you run netstat (ports inside a container are mapped to other ports outside etc).
These messages are harmless and have been removed in a later RabbitMQ version (well, they are now debug level logs so you won't see them by default). It's logged here because the readinessProbe opens a TCP connection but then doesn't send any AMQP data and terminates the connection. The server just reports that it closed all channels related to that connection because the connection was terminated.

Best,



--
Michał
RabbitMQ team
Reply all
Reply to author
Forward
0 new messages