# Node not joining Elasticsearch cluster

**URL:** <https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667>\
**Category:** Elasticsearch\
**Created:** [May 11, 2021, 10:04am UTC](https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667 "2021-05-11T10:04:39Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![ravi-shanker](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ravi-shanker/32/87347_2.png) [@ravi-shanker](https://discuss.elastic.co/u/ravi-shanker)\
**Post date:** [May 11, 2021, 10:04am UTC](https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667/1 "2021-05-11T10:04:39Z")

</div>

I have made an Elasticsearch cluster of 3 nodes but one of the node is not joining the cluster.

Below are my elasticsearch.yml file for all 3 nodes.

NODE1  
cluster.name: ES-Cluster  
node.name: node-1  
node.master: true  
node.data: false  
path.data: /solr-index/Elasticsearch/Elasticdata/elasticsearch  
path.logs: /solr-index/Elasticsearch/elasticsearch  
network.host: ip\_node\_1  
http.port: 9200  
transport.port: 9300  
discovery.zen.ping.unicast.hosts: ["ip\_node\_1", "ip\_node\_2", "ip\_node\_3"]  
cluster.initial\_master\_nodes: ["node-1", "node-2", "node-3"]  
discovery.zen.minimum\_master\_nodes: 2

NODE2  
cluster.name: ES-Cluster  
node.name: node-2  
node.master: true  
node.data: true  
path.data: /solr-index/Elasticsearch/Elasticdata/elasticsearch  
path.logs: /solr-index/Elasticsearch/elasticsearch  
network.host: ip\_node\_2  
http.port: 9200  
transport.port: 9300  
discovery.zen.ping.unicast.hosts: ["ip\_node\_1", "ip\_node\_2", "ip\_node\_3"]  
cluster.initial\_master\_nodes: ["node-1", "node-2", "node-3"]  
discovery.zen.minimum\_master\_nodes: 2

NODE3  
cluster.name: ES-Cluster  
node.name: node-3  
path.data: /solr-index/Elasticsearch/Elasticdata/elasticsearch  
path.logs: /solr-index/Elasticsearch/elasticsearch  
network.host: ip\_node\_3  
http.port: 9200  
transport.port: 9300  
discovery.zen.ping.unicast.hosts: ["ip\_node\_1", "ip\_node\_2", "ip\_node\_3"]  
cluster.initial\_master\_nodes: ["node-1", "node-2", "node-3"]  
discovery.zen.minimum\_master\_nodes: 2

All three nodes are in green status. PFB the output of **curl -XGET 'http://private\_ip:9200/\_cluster/health?pretty'** for all three node

NODE1  
{  
"cluster\_name" : "ES-Cluster",  
"status" : "green",  
"timed\_out" : false,  
"number\_of\_nodes" : 1,  
"number\_of\_data\_nodes" : 1,  
"active\_primary\_shards" : 2,  
"active\_shards" : 2,  
"relocating\_shards" : 0,  
"initializing\_shards" : 0,  
"unassigned\_shards" : 0,  
"delayed\_unassigned\_shards" : 0,  
"number\_of\_pending\_tasks" : 0,  
"number\_of\_in\_flight\_fetch" : 0,  
"task\_max\_waiting\_in\_queue\_millis" : 0,  
"active\_shards\_percent\_as\_number" : 100.0  
}

NODE2  
{  
"cluster\_name" : "ES-Cluster",  
"status" : "green",  
"timed\_out" : false,  
"number\_of\_nodes" : 2,  
"number\_of\_data\_nodes" : 2,  
"active\_primary\_shards" : 12,  
"active\_shards" : 19,  
"relocating\_shards" : 0,  
"initializing\_shards" : 0,  
"unassigned\_shards" : 0,  
"delayed\_unassigned\_shards" : 0,  
"number\_of\_pending\_tasks" : 0,  
"number\_of\_in\_flight\_fetch" : 0,  
"task\_max\_waiting\_in\_queue\_millis" : 0,  
"active\_shards\_percent\_as\_number" : 100.0  
}

NODE3  
{  
"cluster\_name" : "ES-Cluster",  
"status" : "green",  
"timed\_out" : false,  
"number\_of\_nodes" : 2,  
"number\_of\_data\_nodes" : 2,  
"active\_primary\_shards" : 12,  
"active\_shards" : 19,  
"relocating\_shards" : 0,  
"initializing\_shards" : 0,  
"unassigned\_shards" : 0,  
"delayed\_unassigned\_shards" : 0,  
"number\_of\_pending\_tasks" : 0,  
"number\_of\_in\_flight\_fetch" : 0,  
"task\_max\_waiting\_in\_queue\_millis" : 0,  
"active\_shards\_percent\_as\_number" : 100.0  
}

Please help in resolving this issue as I am not able to proceed further because my cluster of 3 node is not getting formed. Also please let me know if any other input is required to help me out on this issue.

Thanks

---

<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:** [May 11, 2021, 10:09am UTC](https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667/2 "2021-05-11T10:09:35Z")

</div>

Which version of Elasticsearch are you using? Given that node 1 reports a green state it would seem it does not use the config file you provided as minimum\_master\_nodes should make it red.

---

<div class="post-metadata">

**Author:** ![ravi-shanker](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ravi-shanker/32/87347_2.png) [@ravi-shanker](https://discuss.elastic.co/u/ravi-shanker)\
**Post date:** [May 11, 2021, 10:16am UTC](https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667/3 "2021-05-11T10:16:16Z")

</div>

I am using ES version 6.8.15 on all the 3 nodes

---

<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:** [May 11, 2021, 2:06pm UTC](https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667/4 "2021-05-11T14:06:27Z")

</div>

How was Elasticsearch installed on these nodes? It does look like node 1 does not use the config file you posted as this should have resulted in a red state on that node. Can you verify that the node is usíng the expected file?

You can also run the cat nodes api on the nodes and check that the roles are as expected.

---

<div class="post-metadata">

**Author:** ![ravi-shanker](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ravi-shanker/32/87347_2.png) [@ravi-shanker](https://discuss.elastic.co/u/ravi-shanker)\
**Post date:** [May 12, 2021, 5:03am UTC](https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667/5 "2021-05-12T05:03:58Z")

</div>

followed below script to install elasticsearch

wget -qO - [https://artifacts.elastic.co/GPG-KEY-elasticsearch](https://artifacts.elastic.co/GPG-KEY-elasticsearch) | sudo apt-key add -

echo "deb [https://artifacts.elastic.co/packages/6.x/apt](https://artifacts.elastic.co/packages/6.x/apt) stable main" | sudo tee -a /etc/apt/sources.list.d/elastic-6.x.list

sudo apt-get update

sudo apt-get install elasticsearch

sudo nano /etc/elasticsearch/elasticsearch.yml

sudo nano /etc/elasticsearch/jvm.options

sudo systemctl start elasticsearch

sudo systemctl enable elasticsearch

sudo systemctl status elasticsearch

now node1 is in green state but not joining the cluster. how to verify if the node is using the expected file ?

---

<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:** [May 12, 2021, 6:11am UTC](https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667/6 "2021-05-12T06:11:39Z")

</div>

What is the output of the cat nodes API?

---

<div class="post-metadata">

**Author:** ![ravi-shanker](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ravi-shanker/32/87347_2.png) [@ravi-shanker](https://discuss.elastic.co/u/ravi-shanker)\
**Post date:** [May 12, 2021, 6:21am UTC](https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667/7 "2021-05-12T06:21:41Z")

</div>

GET /\_cat/nodes

showing node-1 and node-3

All nodes are in green status but node-2 is not joining the cluster. I am stuck with this issue and not able to proceed further.

I have made all 3 nodes as master and data node i.e i have put node.master: true and node.data: true for all three nodes

---

<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:** [May 12, 2021, 7:15am UTC](https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667/8 "2021-05-12T07:15:27Z")

</div>

Please show the full output from all nodes for the cat nodes API.

---

<div class="post-metadata">

**Author:** ![ravi-shanker](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ravi-shanker/32/87347_2.png) [@ravi-shanker](https://discuss.elastic.co/u/ravi-shanker)\
**Post date:** [May 12, 2021, 7:33am UTC](https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667/9 "2021-05-12T07:33:04Z")

</div>

NODE1

ip\_node\_1 50 86 0 0.14 0.07 0.05 mdi \* node-1  
ip\_node\_3 48 93 1 0.02 0.11 0.14 mdi - node-3

NODE2

ip\_node\_2 38 98 0 0.05 0.08 0.08 mdi \* node-2

NODE3

ip\_node\_1 50 86 0 0.11 0.06 0.05 mdi \* node-1  
ip\_node\_3 49 96 10 0.26 0.16 0.16 mdi - node-3

---

<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:** [June 9, 2021, 7:33am UTC](https://discuss.elastic.co/t/node-not-joining-elasticsearch-cluster/272667/10 "2021-06-09T07:33:27Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
