Elasticsearch Cluster setup Issue

(KMG) #1

I tried to setup Elasticsearch cluster in my local LAB.

Setup Scenario :

Server 1 :
IP :
Cluster Name : mycluster
Node name : Node_2

Server 2 :
IP :
Cluster Name : mycluster
Node name : Node_1

Inserted some document in Server 1. But it doesn't replicated in Server 2. Rather than , it shows "Unassigned" option when view the Elasticsearch using head plugin [ ].

(David Pilato) #2

Nodes are not seeing each other.

What is your version?
What can you see in logs?
Check the network connections.
What is your elasticsearch.yml?

(Pandiyan) #3

I guess your nodes are not able to ping with each other. Check the firewall settings or simply add Inbound rules & Outbound rules for ports 9200 & 9300 respectively on nodes. :slight_smile:

(KMG) #4

@pandiyancool ,, , No , Your guess is wrong :smile: .

The problem is fixed, its due to multicast option was set to False on one of the node configuration file.

(Mark Walkom) #5

We do recommend the use of unicast, ES 2.0 will move multicast to a plugin and we will default to unicast instead.

(KMG) #6

oh okay. I will change settings. will get back to u incase of any issues

Mark Walkom noreply@discuss.elastic.co wrote:

(Pandiyan) #7

OK great !!!

(KMG) #8

@warkolm , As per your suggestion , I have changed my settings to unicast. But still have some confusion on data update.

Now, both cluster nodes are shown when check it over head plugin. Then I tried to post some data into in one of the nodes [ ex, updated in Node_2 cluster ]. I could see the same data on Node_3 cluster.

but, when I check the cluster status through head plugin, it shows cluster health in Yellow color. Can you please give some explanation from the above screenshot ? . When cluster health is in Yellow state and why still Unassigned is there ?

Shared : 5
replica : 1

(Mark Walkom) #9

Yellow means you have unassigned replicas.
Why? You should check your logs to see if there is something keeping them from being allocated.

(KMG) #10

Yeah, I checked my logs already. But couldn't find anything suspicious.

Here is the log
[2015-09-21 08:51:14,662][INFO ][node ] [Node_2] initialized
[2015-09-21 08:51:14,662][INFO ][node ] [Node_2] starting ...
[2015-09-21 08:51:14,776][INFO ][transport ] [Node_2] bound_address {inet[/0:0:0:0:0:0:0:0:9300]}, publish_address {inet[/x.x.x.x:9300]}
[2015-09-21 08:51:14,786][INFO ][discovery ] [Node_2] mycluster/v10zYWrHSGSX9nyXLeNg8w
[2015-09-21 08:51:17,803][INFO ][cluster.service ] [Node_2] new_master [Node_2][v10zYWrHSGSX9nyXLeNg8w][logstash.example.com][inet[/x.x.x.x:9300]], reason: zen-disco-join (elected_as_master)
[2015-09-21 08:51:17,842][INFO ][http ] [Node_2] bound_address {inet[/0:0:0:0:0:0:0:0:9200]}, publish_address {inet[/]}
[2015-09-21 08:51:17,843][INFO ][node ] [Node_2] started
[2015-09-21 08:51:17,869][INFO ][gateway ] [Node_2] recovered [0] indices into cluster_state
[2015-09-21 08:51:22,476][INFO ][cluster.service ] [Node_2] added {[Node_3][MD1MbBxmQNesAt0sFA5wig][localhost][inet[/x.x.x.x:9300]],}, reason: zen-disco-receive(join from node[[Node_3][MD1MbBxmQNesAt0sFA5wig][localhost][inet[/x.x.x.x:9300]]])
[2015-09-21 08:51:35,169][INFO ][cluster.metadata ] [Node_2] [mybucket] creating index, cause [api], shards [5]/[1], mappings [doc]

One more question, Why Node_2 shows only 1 and 3. Remaining [ 0,2,4] are shown as Unassigned. Please give some more detail about that.

(KMG) #11

Any idea ?

(Christian Dahlqvist) #12

Are the nodes running the same version of Elasticsearch?

(KMG) #13

No. Each node is running on separate versions

Node 1 version: 1.3.7
Node 2 version : 1.5.2

I don't think that version compatibility is the problem here. Could you please confirm it ?.

(Colin Goodheart-Smithe) #14

Mixed version clusters are not supported for long term use. You should only have a mixed version cluster while upgrading, but you should strive to upgrade all node to the same version as soon as possible.

Elasticsearch will not assign replicas to a node which is on an older version than the node holding the primary shard(s). This is why your replicas are unassigned, you need to upgrade node 1 to be on the same version as node 2.

(system) #15