Cannot create RabbitMQ cluster

589 views
Skip to first unread message

Shahid Zaman

unread,
Feb 10, 2015, 3:38:04 AM2/10/15
to rabbitmq...@googlegroups.com
Hi,

I'm trying to create a RabbitMQ cluster between two CentOS VM's running in VMware fusion in my mac. I'm using rabbitmq 3.4.2 generic unix installer and erlang monolithic rpm from RabbitMQ website.
In /etc/hosts of my mac, I named the ip of VM's as rabbitos (primary VM) and rabbitos1 (secondary VM). I also make sure that erlang cookies in both VM's are same (in the file ~/.erlang.cookie). Then my steps are:

In primary VM:
1. Started rabbitmq server in primary VM.

In secondary VM:
2. Started rabbitmq server.
3. rabbitmqctl stop_app
4. rabbitmqctl join_cluster rabbit@rabitos

Output:

Clustering node rabbit@localhost with rabbit@rabitos ...
Error: unable to connect to nodes [rabbit@rabitos]: nodedown

DIAGNOSTICS
===========

attempted to contact: [rabbit@rabitos]

rabbit@rabitos:
  * connected to epmd (port 4369) on rabitos
  * epmd reports node 'rabbit' running on port 65535
  * TCP connection succeeded but Erlang distribution failed
  * suggestion: hostname mismatch?
  * suggestion: is the cookie set correctly?

current node details:
- node name: 'rabbitmqctl-49252@localhost'
- home dir: /home/sshahid
- cookie hash: Te63nRpH3ub75f5EhwzyQQ==

5. I got the same output if I run the same command with IP address:

rabbitmqctl join_cluster rab...@192.168.177.157

But these two extra lines in the log:

** System NOT running to use fully qualified hostnames **
** Hostname 192.168.177.157 is illegal **
   

So I did few Google searches and found that same cookie is essential which I already fulfilled. The second hint here [1] is to open one more ports in firewall other than 4369 and 25672. So I used the following rabbitmq.config in both VM's and made sure port 65535 is open along with 4369 and 25672 (tested the ports with telnet):

[
{kernel,
[{inet_dist_listen_min, 65535},
{inet_dist_listen_max, 65535}
]
}
].

But I got the exact same result as above. So would appreciate if anyone can comment what is going wrong here.

Thanks.

Shahid

Ronald Marin

unread,
Feb 11, 2015, 10:19:27 AM2/11/15
to rabbitmq...@googlegroups.com
Have you gotten any answer on this? I have the same issue.

Ronald Marin

unread,
Feb 11, 2015, 6:32:55 PM2/11/15
to rabbitmq...@googlegroups.com
Hey i got mine working, make sure you have an enter in your /etc/hosts file for your node, make sure the entry does not contain the rabbit@rabitos but instead rabitos by itself.


On Tuesday, February 10, 2015 at 3:38:04 AM UTC-5, Shahid Zaman wrote:

Shahid Zaman

unread,
Feb 12, 2015, 10:49:14 PM2/12/15
to rabbitmq...@googlegroups.com
I guess I had the right entries in my mac's /ets/hosts file:

192.168.177.157 rabitos

192.168.177.159 rabitos1 

Regards
Shahid
Reply all
Reply to author
Forward
0 new messages