1

I am trying to set up a HA rabbit mq cluster and I am following the instruction in https://www.rabbitmq.com/clustering.html

The first rabbit mq server is fine, whereas in the second and third rabbitmq servers I am getting the below error,

Kernel pid terminated (application_controller) ({application_start_failure,kernel,{{shutdown,{failed_to_start_child,net_sup,{shutdown,{failed_to_start_child,auth,{"Cookie file /var/lib/rabbitmq/.erl

I have double check /var/lib/rabbitmq/.erlang.cookie on all three servers have the same value. Stuck with this error, any help on this is appreciated

g0c00l.g33k
  • 2,458
  • 2
  • 31
  • 41
  • By the way, the error message appears as truncated but it is not - I triple checked it in erl_crash.dump as well, that is the complete error message – g0c00l.g33k Dec 18 '14 at 10:05
  • The .erlang.cookie usually resides in the home directory of the user that is running rabbitmq. Can you move the cookie to ~/ and try if they start up – JVXR Dec 18 '14 at 17:48
  • Tried that too, and doesn't work. Having the same issue – g0c00l.g33k Dec 19 '14 at 01:33
  • Can you please post the output of netstat -an | grep 5672 (this has to be run on the hosts that the node cannot start). I'm trying to see if some other application is using that port. – JVXR Dec 19 '14 at 17:24
  • When I do a netstat -an | grep 5672 I see nothing – g0c00l.g33k Jan 10 '15 at 02:25

1 Answers1

2

Maybe it is too late but I run into this same issue. Here how I solved it:

  1. Run rabbitmqctl status (as root or use sudo). It gave me some error messages. One of them was:

{error_logger,{{2016,9,20},{12,4,22}},"Cookie file /var/lib/rabbitmq/.erlang.cookie must be accessible by owner only",[]}

  1. Then run ls -l /var/lib/rabbitmq/.erlang.cookie. It returns to me this:

-rwxrwxrwx 1 rabbitmq rabbitmq 20 Set 25 2014 /var/lib/rabbitmq/.erlang.cookie

  1. Then change the permissions using chmod 600 /var/lib/rabbitmq/.erlang.cookie

I think other users may have to change the ownership too. It was not my case tough.

Eiko
  • 25,601
  • 15
  • 56
  • 71
Emerson Pardo
  • 151
  • 1
  • 9