# Problems With Local Elasticsearch VM Cluster Communication

**URL:** <https://discuss.elastic.co/t/problems-with-local-elasticsearch-vm-cluster-communication/31559>\
**Category:** Elasticsearch\
**Created:** [October 2, 2015, 5:25pm UTC](https://discuss.elastic.co/t/problems-with-local-elasticsearch-vm-cluster-communication/31559 "2015-10-02T17:25:08Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![zylo47](https://avatars.discourse-cdn.com/v4/letter/z/5fc32e/32.png) [@zylo47](https://discuss.elastic.co/u/zylo47)\
**Post date:** [October 2, 2015, 5:25pm UTC](https://discuss.elastic.co/t/problems-with-local-elasticsearch-vm-cluster-communication/31559/1 "2015-10-02T17:25:09Z")

</div>

I am trying to setup a local VM cluster of 3 Elasticsearch servers. I started with a single, stand-alone server running through VirtualBox with the Centos 6.6 operating system, then I cloned it so I now have 3 VMs, all running Elasticsearch 1.3.2. (the version of Elasticsearch must be 1.3.2 because our production environment is 1.3.2, I am trying to test some changes locally).

The problem I am having is that every time I try to setup the clustering, the servers fail to communicate with each other due to the following error

> [2015-10-02 17:13:32,129][WARN][http.netty] [NYCVM7531] Caught exception while handling client http traffic, closing connection [id: 0xa47a7885, /10.18.0.184:38136 =\> /10.18.0.101:9200]  
> java.lang.IllegalArgumentException: invalid version format: NYCVM7531\_1^K10.18.0.184

The servers are not in DNS. They are getting a DHCP IP address. They are called NYCVM7531, NYCVM7531\_1, and NYCVM7531\_2. The IPs are 10.18.0.101, 10.18.0.184, and 10.18.0.185. Each have entries in their local /etc/hosts file so they can ping each other.

I have named the cluster NYCVM7531\_Cluster in each of the elasticsearch.yml files. I have set discovery.zen.ping.multicast.enabled to false on each node. I have also set discovery.zen.ping.unicast.hosts to ["NYCVM7531:9200","NYCVM7531\_1:9200","NYCVM7531\_2:9200"]

Here is what iptables looks like on all three nodes. I don't think it's a port issue but I am unsure:

> Table: filter  
> Chain INPUT (policy ACCEPT)  
> num target prot opt source destination  
> 1 ACCEPT all -- 0.0.0.0/0 0.0.0.0/0 state RELATED,ESTABLISHED  
> 2 ACCEPT icmp -- 0.0.0.0/0 0.0.0.0/0  
> 3 ACCEPT all -- 0.0.0.0/0 0.0.0.0/0  
> 4 ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 state NEW tcp dpt:22  
> 5 ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 state NEW tcp dpt:9200  
> 6 ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 state NEW tcp dpt:9300  
> 7 REJECT all -- 0.0.0.0/0 0.0.0.0/0 reject-with icmp-host-prohibited

> Chain FORWARD (policy ACCEPT)  
> num target prot opt source destination  
> 1 REJECT all -- 0.0.0.0/0 0.0.0.0/0 reject-with icmp-host-prohibited

> Chain OUTPUT (policy ACCEPT)  
> num target prot opt source destination

If I change minimum master nodes from 1 to 2 the cluster fails to start because none of the nodes can talk. When it is set to 1 they only see themselves.

I don't know what the problem could be. Please help.

_update_ I tried shutting the firewall off using sudo service iptables stop on all 3 nodes and then restarting elasticsearch, same issue.

---

<div class="post-metadata">

**Author:** ![zylo47](https://avatars.discourse-cdn.com/v4/letter/z/5fc32e/32.png) [@zylo47](https://discuss.elastic.co/u/zylo47)\
**Post date:** [October 2, 2015, 6:34pm UTC](https://discuss.elastic.co/t/problems-with-local-elasticsearch-vm-cluster-communication/31559/2 "2015-10-02T18:34:02Z")

</div>

I fixed the problem. I had to remove the port specification out of the unicast.hosts entries

instead of "NYCVM7531:9200" i just put "NYCVM7531" and it started working.

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [October 2, 2015, 6:36pm UTC](https://discuss.elastic.co/t/problems-with-local-elasticsearch-vm-cluster-communication/31559/3 "2015-10-02T18:36:37Z")

</div>

9200 is the default port for HTTP traffic. Internal cluster traffic uses the 9300 port.

---

<div class="post-metadata">

**Author:** ![zylo47](https://avatars.discourse-cdn.com/v4/letter/z/5fc32e/32.png) [@zylo47](https://discuss.elastic.co/u/zylo47)\
**Post date:** [October 2, 2015, 6:37pm UTC](https://discuss.elastic.co/t/problems-with-local-elasticsearch-vm-cluster-communication/31559/4 "2015-10-02T18:37:55Z")

</div>

So i was basically crossing wires by trying to force it to use 9200 when it would have tried to use 9300?

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [October 3, 2015, 11:42pm UTC](https://discuss.elastic.co/t/problems-with-local-elasticsearch-vm-cluster-communication/31559/5 "2015-10-03T23:42:33Z")

</div>

Yep 🙂

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 5, 2017, 11:46pm UTC](https://discuss.elastic.co/t/problems-with-local-elasticsearch-vm-cluster-communication/31559/6 "2017-07-05T23:46:53Z")

</div>


