# Adding a node to a cluster

**URL:** <https://discuss.elastic.co/t/adding-a-node-to-a-cluster/173958>\
**Category:** Elasticsearch\
**Created:** [March 26, 2019, 3:25pm UTC](https://discuss.elastic.co/t/adding-a-node-to-a-cluster/173958 "2019-03-26T15:25:50Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![sph18](https://avatars.discourse-cdn.com/v4/letter/s/a183cd/32.png) [@sph18](https://discuss.elastic.co/u/sph18)\
**Post date:** [March 26, 2019, 3:25pm UTC](https://discuss.elastic.co/t/adding-a-node-to-a-cluster/173958/1 "2019-03-26T15:25:50Z")

</div>

Hi all,

I have a graylog server setup as a single host. Version are:

Host - Ubuntu 18.04  
Graylog - 3.0.0-12  
Java - 1.8.0\_191  
Elasticsearch - 6.6.2"  
MongoDB - 4.0.6  
Apache - 2.4.29

So I'm I want to add a node the a single cluster. I set up the new host, specs are:

Host - Ubuntu 18.04  
Java - 1.8.0\_191  
Elasticsearch - 6.6.2"

I edited my /etc/elasticsearch/elasticsearch.yml and it looks like this:

> cluster.name: graylog  
> node.name: crow  
> node.data: true
> 
> path.logs: /var/log/elasticsearch
> 
> discovery.zen.ping.unicast.hosts: ["172.24.228.161","172.24.228.226"]

.161 is my single graylog server and 226 is the new node. ES has been restarted. I have then edited my single graylog ES conf, which looks like this:

> cluster.name: graylog  
> action.auto\_create\_index: false  
> node.master: true
> 
> node.name: grayone
> 
> path.logs: /var/log/elasticsearch
> 
> discovery.zen.ping.unicast.hosts: ["172.24.228.161","172.24.228.226"]

Config based on ES guide -

> **[Adding nodes to your cluster | Elasticsearch Guide \[6.6\] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/6.6/add-elasticsearch-nodes.html)**

> **[Node | Elasticsearch Guide \[6.6\] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/6.6/modules-node.html)**

But when I go into graylog and check nodes the new one is not there. Doing a ```  
curl -XGET '[http://127.0.0.1:9200/\_cluster/health?pretty=true](http://127.0.0.1:9200/_cluster/health?pretty=true)'

```auto

> {
> "cluster_name" : "graylog",
> "status" : "green",
> "timed_out" : false,
> "number_of_nodes" : 1,
> "number_of_data_nodes" : 1,
> "active_primary_shards" : 28,
> "active_shards" : 28,
> "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
> }

 Both servers can ping each other. There aren't any errors in the graylog.log on either host
Have I missed something in the config?
```

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [March 26, 2019, 3:40pm UTC](https://discuss.elastic.co/t/adding-a-node-to-a-cluster/173958/2 "2019-03-26T15:40:20Z")

</div>

Most likely you missed `network.host` setting.

---

<div class="post-metadata">

**Author:** ![sph18](https://avatars.discourse-cdn.com/v4/letter/s/a183cd/32.png) [@sph18](https://discuss.elastic.co/u/sph18)\
**Post date:** [March 26, 2019, 4:19pm UTC](https://discuss.elastic.co/t/adding-a-node-to-a-cluster/173958/3 "2019-03-26T16:19:44Z")

</div>

Thanks for the reply dadoonet.  
I've added in network.host:IP on both hosts, but not getting some errors.

When running curl -XGET '[http://127.0.0.1:9200/\_cluster/health?pretty=true](http://127.0.0.1:9200/_cluster/health?pretty=true)'

I get back:

> curl: (7) Failed to connect to 127.0.0.1 port 9200: Connection refused

and checking the ES logs and I'm getting

> [2019-03-26T16:11:34,499][INFO][o.e.d.z.ZenDiscovery] [grayone] failed to send join request to master [{crow}{KQtVL-x1TbWLGcvDiGyXLA}{4\_Ae58sDRty8Dwa6i-Zouw}{172.24.228.226}{172.24.228.226:9300}{ml.machine\_memory=67529670656, ml.max\_open\_jobs=20, xpack.installed=true, ml.enabled=true}], reason [RemoteTransportException[[crow][172.24.228.226:9300][internal:discovery/zen/join]]; nested: IllegalStateException[failure when sending a validation request to node]; nested: RemoteTransportException[[grayone][172.24.228.161:9300][internal:discovery/zen/join/validate]]; nested: IllegalArgumentException[Unknown NamedWriteable [org.elasticsearch.cluster.metadata.MetaData$Custom][licenses]]; ]

From that I can see it's failing because of "RemoteTransportException", but I've not come across it in the documentation (sorry new the ES) ?

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [March 26, 2019, 11:10pm UTC](https://discuss.elastic.co/t/adding-a-node-to-a-cluster/173958/4 "2019-03-26T23:10:32Z")

</div>

Please format your code, logs or configuration files using `</>` icon as explained in [this guide](https://discuss.elastic.co/t/about-the-elasticsearch-category/21) and not the citation button. It will make your post more readable.

Or use markdown style like:

````
```
CODE
```

````

This is the icon to use if you are not using markdown format:

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/7/e/7e6e239431ec2d71cbf1beef741f2e93e7cc762c.jpg)

Few things:

Your node is now listening on a given IP. You can't query it using `127.0.0.1`. See the logs to see the http address and port.

It's failing to join the cluster because of an unknown setting or something like this. Not sure what it is.

---

<div class="post-metadata">

**Author:** ![mujtabahussain](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mujtabahussain/32/17514_2.png) [@mujtabahussain](https://discuss.elastic.co/u/mujtabahussain)\
**Post date:** [March 27, 2019, 4:25am UTC](https://discuss.elastic.co/t/adding-a-node-to-a-cluster/173958/5 "2019-03-27T04:25:56Z")

</div>

Can you telnet between the hosts on ports 9200 and 9300?

---

<div class="post-metadata">

**Author:** ![sph18](https://avatars.discourse-cdn.com/v4/letter/s/a183cd/32.png) [@sph18](https://discuss.elastic.co/u/sph18)\
**Post date:** [March 27, 2019, 8:57am UTC](https://discuss.elastic.co/t/adding-a-node-to-a-cluster/173958/6 "2019-03-27T08:57:13Z")

</div>

Apologies dadoonet, Have read now.

OK so I when through the ES conf and there was no ref to 127. Checking the Graylog conf there was a 127 address in the "List of Elasticsearch hosts Graylog should connect to."

I've changed the setting to be:

> Default: [http://172.24.228.226:9200](http://172.24.228.226:9200),[http://172.24.228.161:9200](http://172.24.228.161:9200)

also enabled is

> elasticsearch\_discovery\_enabled = true

This is a warning with this setting

> WARNING: Automatic node discovery does not work if Elasticsearch requires authentication, e. g. with Shield

But I have not set up any authentication

Checking back in the logs on the graylog its states

`[2019-03-27T08:45:00,934][INFO][o.e.d.z.ZenDiscovery] [grayone] failed to send join request to master [{crow}{KQtVL-x1TbWLGcvDiGyXLA}{4_Ae58sDRty8Dwa6i-Zouw}{172.24.228.226}{172.24.228.226:9300}{ml.machine_memory=67529670656, ml.max_open_jobs=20, xpack.installed=true, ml.enabled=true}], reason [RemoteTransportException[[crow][172.24.228.226:9300][internal:discovery/zen/join]]; nested: IllegalStateException[failure when sending a validation request to node]; nested: RemoteTransportException[[grayone][172.24.228.161:9300][internal:discovery/zen/join/validate]]; nested: IllegalArgumentException[Unknown NamedWriteable [org.elasticsearch.cluster.metadata.MetaData$Custom][licenses]]; ]`

From that It looks like its failing because of the validation request it trying to make, but I'm not sure what the validation is?

---

<div class="post-metadata">

**Author:** ![sph18](https://avatars.discourse-cdn.com/v4/letter/s/a183cd/32.png) [@sph18](https://discuss.elastic.co/u/sph18)\
**Post date:** [March 27, 2019, 8:58am UTC](https://discuss.elastic.co/t/adding-a-node-to-a-cluster/173958/7 "2019-03-27T08:58:11Z")

</div>

Hi mujtabahussain,

Yea I can telnet to both 9200 and 9300 on both nodes. I can nav in the browser to [http://172.24.228.161:9200/](http://172.24.228.161:9200/) and get my ES info and when going to 9300 I get back

> This is not an HTTP port

---

<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:** [April 24, 2019, 8:58am UTC](https://discuss.elastic.co/t/adding-a-node-to-a-cluster/173958/8 "2019-04-24T08:58:16Z")

</div>

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