# "master not discovered exception" after having 999 of 1000 max. shards open

**URL:** <https://discuss.elastic.co/t/master-not-discovered-exception-after-having-999-of-1000-max-shards-open/207066>\
**Category:** Elasticsearch\
**Created:** [November 8, 2019, 7:40am UTC](https://discuss.elastic.co/t/master-not-discovered-exception-after-having-999-of-1000-max-shards-open/207066 "2019-11-08T07:40:47Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![anli](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/anli/32/57362_2.png) [@anli](https://discuss.elastic.co/u/anli)\
**Post date:** [November 8, 2019, 7:40am UTC](https://discuss.elastic.co/t/master-not-discovered-exception-after-having-999-of-1000-max-shards-open/207066/1 "2019-11-08T07:40:47Z")

</div>

Hello there,  
I'm migrating my live data from our live elasticsearch server to our archive elasticsearch server. Both are single nodes. While doing this I missed to close indices on the archive server. Using curator I got the error "Validation Failed: 1: this action would add [2] total shards, but this cluster currently has [999]/[1000] maximum shards open;" somewhere while executing the task. I tried to close indices on the archive server, but I always get "master\_not\_discovered\_exception", regardless of what I'm trying to do, e. g. quering some statistics from the archive:

> ```
> root@elk-archive-01 ~ # curl -X GET "10.0.0.210:9200/_cluster/health?wait_for_status=yellow&timeout=50s&pretty"
> {
> "error" : {
> "root_cause" : [
> {
> "type" : "master_not_discovered_exception",
> "reason" : null
> }
> ],
> "type" : "master_not_discovered_exception",
> "reason" : null
> },
> "status" : 503
> }
> 
> ```

In the logs the following lines are suspicous:

> ```
> failing [elected-as-master ([1] nodes joined)[{elk-archive-01-n1}{QGFmDMAITRu4JNov0SwH1Q}{RbaWF3t7QKyXKWDa3fEbYw}{10.0.0.210}{10.0.0.210:9300}{dilm}{ml.machine_memory=33449811968, xpack.installed=true, ml.max_open_jobs=20} elect leader, _BECOME_MASTER_TASK_, _FINISH_ELECTION_]]: failed to commit cluster state version [19845]
> org.elasticsearch.cluster.coordination.FailedToCommitClusterStateException: publication failed
> [...]
> Caused by: org.elasticsearch.ElasticsearchException: publication cancelled before committing: timed out after 30s
> 
> ```

Unfortunately I don't know where to upload the whole logfile ☹

How can I close the indices to get the server back up again? Thanks a lot for your help!

---

<div class="post-metadata">

**Author:** ![anli](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/anli/32/57362_2.png) [@anli](https://discuss.elastic.co/u/anli)\
**Post date:** [November 8, 2019, 8:06am UTC](https://discuss.elastic.co/t/master-not-discovered-exception-after-having-999-of-1000-max-shards-open/207066/2 "2019-11-08T08:06:56Z")

</div>

Ok, following "[Can not elect master when restarting cluster from 7.3 upgrade](https://discuss.elastic.co/t/can-not-elect-master-when-restarting-cluster-from-7-3-upgrade/197846/19)" fixed the problem.

---

<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:** [December 6, 2019, 8:06am UTC](https://discuss.elastic.co/t/master-not-discovered-exception-after-having-999-of-1000-max-shards-open/207066/3 "2019-12-06T08:06:59Z")

</div>

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