# Updating nodes in Elasticsearch cluster

**URL:** <https://discuss.elastic.co/t/updating-nodes-in-elasticsearch-cluster/228737>\
**Category:** Elasticsearch\
**Tags:** docker\
**Created:** [April 19, 2020, 2:47pm UTC](https://discuss.elastic.co/t/updating-nodes-in-elasticsearch-cluster/228737 "2020-04-19T14:47:56Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![vbhat](https://avatars.discourse-cdn.com/v4/letter/v/71e660/32.png) [@vbhat](https://discuss.elastic.co/u/vbhat)\
**Post date:** [April 19, 2020, 2:47pm UTC](https://discuss.elastic.co/t/updating-nodes-in-elasticsearch-cluster/228737/1 "2020-04-19T14:47:56Z")

</div>

Hi,

We have an Elasticsearch cluster for centralised log analysis in HashiCorp Nomad cluster. We are aware that ES is a stateful application and would not benefit much from the orchestrator such as HashiCorp Nomad. But we are running there to be consistent with our other application management. Below is our current setup.

We have a terraform module to create Nomad + Consul cluster, which launches an AWS autoscaling group with min=max. We don't want to autoscale here but still use ASG for ease of integration with AWS load balancers and ease of node upgrades. In case of ES we launch 3 instances with some particular tags. And during the launch of new ES cluster in Nomad, we make use of these tags to automatically populate the `cluster.initial_master_nodes`. So using this we are able to work around the limitation of bootstrapping with 7.x version which otherwise requries a hardcodes values. And each of these 3 nodes act as as master eligible and data nodes. They have an EBS volume attached which is being used as ES data directory for persitance.

Now, the concern is node upgrades. Not sure how to go about updating the nodes. I want to replace these nodes with new nodes and attach the EBS volumes there for data. Below are my specific questions.

1. Once the initial cluster is formed, should I remove the `cluster.initial_master_nodes` option?
2. Can I simply shut down one node, launch a new node attach the EBS volume and start ES without data loss? If yes, can I repeat the same process for update the whole cluster?
3. Should I still follow the instructions in this guide for upgrades? [https://www.elastic.co/guide/en/elasticsearch/reference/7.6/setup-upgrade.html](https://www.elastic.co/guide/en/elasticsearch/reference/7.6/setup-upgrade.html)

Please let me know I overlooked some document/guide. Any help is appreciated.

Thanks

Best Regards,  
Vishwanath

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [April 19, 2020, 4:26pm UTC](https://discuss.elastic.co/t/updating-nodes-in-elasticsearch-cluster/228737/2 "2020-04-19T16:26:06Z")

</div>

> [@vbhat](#):
>
> 1. Once the initial cluster is formed, should I remove the `cluster.initial_master_nodes` option?

[Yes](https://www.elastic.co/guide/en/elasticsearch/reference/current/discovery-settings.html#initial_master_nodes).

> [@vbhat](#):
>
> 1. Can I simply shut down one node, launch a new node attach the EBS volume and start ES without data loss? If yes, can I repeat the same process for update the whole cluster?

Yes, and yes.

> [@vbhat](#):
>
> 1. Should I still follow the instructions in this guide for upgrades? [Upgrade Elasticsearch | Elasticsearch Guide [7.6] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/7.6/setup-upgrade.html)

Yes.

---

<div class="post-metadata">

**Author:** ![vbhat](https://avatars.discourse-cdn.com/v4/letter/v/71e660/32.png) [@vbhat](https://discuss.elastic.co/u/vbhat)\
**Post date:** [April 19, 2020, 5:52pm UTC](https://discuss.elastic.co/t/updating-nodes-in-elasticsearch-cluster/228737/3 "2020-04-19T17:52:40Z")

</div>

That was quick. Thanks for the confirmation. I will try it next week and update here 🙂

---

<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:** [May 17, 2020, 5:52pm UTC](https://discuss.elastic.co/t/updating-nodes-in-elasticsearch-cluster/228737/4 "2020-05-17T17:52:50Z")

</div>

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