# How can i make data node as master

**URL:** <https://discuss.elastic.co/t/how-can-i-make-data-node-as-master/58647>\
**Category:** Elasticsearch\
**Created:** [August 23, 2016, 5:50am UTC](https://discuss.elastic.co/t/how-can-i-make-data-node-as-master/58647 "2016-08-23T05:50:29Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Akshay\_Kumar](https://avatars.discourse-cdn.com/v4/letter/a/54ee81/32.png) [@Akshay\_Kumar](https://discuss.elastic.co/u/Akshay_Kumar)\
**Post date:** [August 23, 2016, 5:50am UTC](https://discuss.elastic.co/t/how-can-i-make-data-node-as-master/58647/1 "2016-08-23T05:50:29Z")

</div>

i have created a cluster with 1 master and 3 data node . if my master is down i what to make data node as a master

will this work ?  
node.master: true  
node.data: true

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [August 23, 2016, 6:00am UTC](https://discuss.elastic.co/t/how-can-i-make-data-node-as-master/58647/2 "2016-08-23T06:00:19Z")

</div>

Yes, but I'm pretty sure you don't want to make this change after the master has gone down. At that point the data nodes have no knowledge of the cluster state and I suspect that turning one of them into a master might cause data loss.

Given that you'll want to have at least three master-eligible nodes (you obviously need more than one to avoid a single point of failure and you need more than two to avoid split brain situations) I suggest that you make all nodes of your small cluster master-eligible.

---

<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:** [August 23, 2016, 6:14am UTC](https://discuss.elastic.co/t/how-can-i-make-data-node-as-master/58647/3 "2016-08-23T06:14:23Z")

</div>

As Magnus points out the key is to have at least 3 master eligible nodes so that another can step in when one fails. When changing this, make sure to update the [minimum\_master\_nodes](https://www.elastic.co/guide/en/elasticsearch/reference/2.3/modules-node.html#split-brain) setting in the elasticsearch.yml config files in order to avoid split brain scenarios. If you make all 4 of your nodes master eligible, this should be set to 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:** [July 5, 2017, 10:25pm UTC](https://discuss.elastic.co/t/how-can-i-make-data-node-as-master/58647/4 "2017-07-05T22:25:58Z")

</div>


