title: Can't join rabbitMQ cluster: Error: nodedown
body: <p>I am new to rabbitMQ and Linux.
  I am following clustering guide at 
  <a href="https://www.rabbitmq.com/clustering.html" rel="nofollow">https://www.rabbitmq.com/clustering.html</a></p>
  
  <p>I have three nodes all running CentOS 7 (On virtual machines with statics IPs).</p>
  
  <p>I have copied the erlang cookie to all machines.</p>
  
  <p>I have set hosts in hosts file as the following
  This on machine 2</p>
  
  <pre><code>127.0.0.1   localhost localhost.localdomain localhost4   localhost4.localdomain4
  ::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
  192.168.198.100   rabbit1
  127.0.0.1 rabbit2
  192.168.198.102   rabbit3
  </code></pre>
  
  <p>But hen trying to join rabbit2 to rabbit1 using</p>
  
  <pre><code>rabbitmqctl join_cluster rabbit@rabbit1
  </code></pre>
  
  <p>I get the following error</p>
  
  <pre><code>Clustering node rabbit@localhost with rabbit@rabbit1 ...
  Error: unable to connect to nodes [rabbit@rabbit1]: nodedown
  
  DIAGNOSTICS
  ===========
  
  attempted to contact: [rabbit@rabbit1]
  
  rabbit@rabbit1:
    * connected to epmd (port 4369) on rabbit1
    * epmd reports node 'rabbit' running on port 25672
    * TCP connection succeeded but Erlang distribution failed
    * suggestion: hostname mismatch?
    * suggestion: is the cookie set correctly?
    * suggestion: is the Erlang distribution using TLS?
  
  current node details:
  - node name: 'rabbitmq-cli-72@localhost'
  - home dir: /var/lib/rabbitmq
  - cookie hash: YlXmRhqgpV9H7lgqXslI1g==
  </code></pre>
  
  <p>Could anyone help me figure out what's wrong with this?</p>