# Lost whole data after restarting ES

**URL:** <https://discuss.elastic.co/t/lost-whole-data-after-restarting-es/14768>\
**Category:** Elasticsearch\
**Created:** [December 9, 2013, 11:53am UTC](https://discuss.elastic.co/t/lost-whole-data-after-restarting-es/14768 "2013-12-09T11:53:57Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dina](https://avatars.discourse-cdn.com/v4/letter/d/f0a364/32.png) [@Dina](https://discuss.elastic.co/u/Dina)\
**Post date:** [December 9, 2013, 11:53am UTC](https://discuss.elastic.co/t/lost-whole-data-after-restarting-es/14768/1 "2013-12-09T11:53:57Z")

</div>

Hello,

We have 6 indexes on 5 nodes each shard on a node with no replic.

I had a red health on ES today , which appears to be that one shard of one  
index unassigned due to full disk space,  
After emptying the server from dummy data. I restarted the node that should  
have the unassigned node , but it didn't work at All.

Then restarted the whole nodes and had 5 shards unassigned.

I have on my configurations  
cluster.routing.allocation.disable\_allocation: true

After that we changed the configurations to  
cluster.routing.allocation.disable\_new\_allocation: true  
cluster.routing.allocation.disable\_allocation: true  
cluster.routing.allocation.allow\_primary: true

and restarted the whole node.  
After that the whole shards become unassigned and we discovered that the  
data on the hard disk is also removed.

I want to make sure, what we did wrong so we wont that again.

How can I recover unassigned shard for future ? is it by restart ?

Dina

--  
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).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/c9933972-d0d1-4afc-85c8-d1b5058352da%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/c9933972-d0d1-4afc-85c8-d1b5058352da%40googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![jprante](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jprante/32/44941_2.png) [@jprante](https://discuss.elastic.co/u/jprante)\
**Post date:** [December 9, 2013, 12:21pm UTC](https://discuss.elastic.co/t/lost-whole-data-after-restarting-es/14768/2 "2013-12-09T12:21:16Z")

</div>

You had disabled replica? Sorry , then I have no answer.

I guess you lost a shard and with the broken shard, the whole index can be  
gone. It is a known risk you can lose an index if you run out of disk space  
without having replica on an unaffected node.

Shard replica level 1 is active by default for good reason. They are for  
failsafety, beside query load balancing.

Jörg

--  
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).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAKdsXoGB3GtT0a9LLXdsmX%2BWJ7pa%2BavXbUmXPDL0kvj4R\_q72A%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAKdsXoGB3GtT0a9LLXdsmX%2BWJ7pa%2BavXbUmXPDL0kvj4R_q72A%40mail.gmail.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:02am UTC](https://discuss.elastic.co/t/lost-whole-data-after-restarting-es/14768/3 "2017-07-06T02:02:30Z")

</div>


