# Reassign an elected master

**URL:** <https://discuss.elastic.co/t/reassign-an-elected-master/12867>\
**Category:** Elasticsearch\
**Created:** [July 20, 2013, 1:19am UTC](https://discuss.elastic.co/t/reassign-an-elected-master/12867 "2013-07-20T01:19:04Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![vinh](https://avatars.discourse-cdn.com/v4/letter/v/34f0e0/32.png) [@vinh](https://discuss.elastic.co/u/vinh)\
**Post date:** [July 20, 2013, 1:19am UTC](https://discuss.elastic.co/t/reassign-an-elected-master/12867/1 "2013-07-20T01:19:04Z")

</div>

Is there a best practice on reassigning an elected master? For example, if I need to take down that master for maintenance.

Thanks,  
-Vinh

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![drewr](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/drewr/32/7803_2.png) [@drewr](https://discuss.elastic.co/u/drewr)\
**Post date:** [July 20, 2013, 3:45am UTC](https://discuss.elastic.co/t/reassign-an-elected-master/12867/2 "2013-07-20T03:45:22Z")

</div>

vinh wrote:

> Is there a best practice on reassigning an elected master? For  
> example, if I need to take down that master for maintenance.

You should stop it gracefully using either the API or giving the  
java process a TERM.

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

Easiest way is to run this from the cluster:

```
curl -XPOST localhost:9200/_cluster/nodes/_master/_shutdown

```

Make sure that if you have minimum\_master\_nodes set there are  
enough leftover that the cluster can tolerate losing one of them.

Drew

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![vinh](https://avatars.discourse-cdn.com/v4/letter/v/34f0e0/32.png) [@vinh](https://discuss.elastic.co/u/vinh)\
**Post date:** [July 22, 2013, 9:12am UTC](https://discuss.elastic.co/t/reassign-an-elected-master/12867/3 "2013-07-22T09:12:30Z")

</div>

Thanks Drew!  
-Vinh

On Jul 19, 2013, at 8:45 PM, Drew Raines [aaraines@gmail.com](mailto:aaraines@gmail.com) wrote:

> vinh wrote:
> 
> > Is there a best practice on reassigning an elected master? For example, if I need to take down that master for maintenance.
> 
> You should stop it gracefully using either the API or giving the java process a TERM.
> 
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/reference/api/admin-cluster-nodes-shutdown/)
> 
> Easiest way is to run this from the cluster:
> 
> curl -XPOST localhost:9200/\_cluster/nodes/\_master/\_shutdown
> 
> Make sure that if you have minimum\_master\_nodes set there are enough leftover that the cluster can tolerate losing one of them.
> 
> Drew

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<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 6, 2017, 2:25am UTC](https://discuss.elastic.co/t/reassign-an-elected-master/12867/4 "2017-07-06T02:25:15Z")

</div>


