# What will happen if elasticsearch all node goes down? Did we loose all data In this case?

**URL:** https://discuss.elastic.co/t/what-will-happen-if-elasticsearch-all-node-goes-down-did-we-loose-all-data-in-this-case/265923
**Category:** Elasticsearch
**Tags:** elastic-stack-security
**Created:** [March 2, 2021, 8:34am UTC](https://discuss.elastic.co/t/what-will-happen-if-elasticsearch-all-node-goes-down-did-we-loose-all-data-in-this-case/265923 "2021-03-02T08:34:22Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Mangesh\_Mandavgane](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mangesh_mandavgane/32/84788_2.png) [@Mangesh\_Mandavgane](https://discuss.elastic.co/u/Mangesh_Mandavgane)
#### Post date: [March 2, 2021, 8:34am UTC](https://discuss.elastic.co/t/what-will-happen-if-elasticsearch-all-node-goes-down-did-we-loose-all-data-in-this-case/265923/1 "2021-03-02T08:34:22Z")

</div>

While reading about Elasticsearch I understood that Nodes have Shards. And we can make configuration for Primary and Replica Shards. If one of node goes down it retrieve data from replica shards which is in another node.

But I want to understand more, What If all nodes goes down, How it will recover Or How we can recover data.?? Is there any Backup strategy ??

---

<div class="post-metadata">

### Author: ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)
#### Post date: [March 2, 2021, 8:58am UTC](https://discuss.elastic.co/t/what-will-happen-if-elasticsearch-all-node-goes-down-did-we-loose-all-data-in-this-case/265923/2 "2021-03-02T08:58:57Z")

</div>

Welcome!

All data are stored on disk so when you restart the nodes data will be again available.

You can test this locally with one single node:

- start the node
- index some data
- stop the node
- restart the node
- search for your data

---

<div class="post-metadata">

### Author: ![Mangesh\_Mandavgane](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mangesh_mandavgane/32/84788_2.png) [@Mangesh\_Mandavgane](https://discuss.elastic.co/u/Mangesh_Mandavgane)
#### Post date: [March 2, 2021, 9:45am UTC](https://discuss.elastic.co/t/what-will-happen-if-elasticsearch-all-node-goes-down-did-we-loose-all-data-in-this-case/265923/3 "2021-03-02T09:45:37Z")

</div>

Hi @dadoonet thanks, I tried it is working fine as you said. But, What if Disk failure occurred. Is there any Backup strategy given by Elasticsearch for disk. Or we should take Manually Backup of the disk?? Or What is the best practice we should follow for Production Environment ??

---

<div class="post-metadata">

### Author: ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)
#### Post date: [March 2, 2021, 10:13am UTC](https://discuss.elastic.co/t/what-will-happen-if-elasticsearch-all-node-goes-down-did-we-loose-all-data-in-this-case/265923/4 "2021-03-02T10:13:40Z")

</div>

Have a hard disk failure on a replica and at a same time on a primary is pretty much uncommon, but let say you are really unlucky. You can do many things:

- increase the number of replicas if you want to take less risks that your data is not available online anymore. So now, to make it fail, you need to have not only 2 hard disk crash but 3, 4, 5 or more... It comes at the cost of disk space usage of course.
- use snapshot/restore (which is recommended). Use SLM (Snapshot Lifecycle Management) to make that even easier to manage. [Tutorial: Automate backups with SLM | Elasticsearch Reference [7.11] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/current/getting-started-snapshot-lifecycle-management.html)
- use cross cluster replication: [Cross-cluster replication | Elasticsearch Reference [7.11] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/current/xpack-ccr.html)

---

<div class="post-metadata">

### Author: ![Mangesh\_Mandavgane](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mangesh_mandavgane/32/84788_2.png) [@Mangesh\_Mandavgane](https://discuss.elastic.co/u/Mangesh_Mandavgane)
#### Post date: [March 2, 2021, 10:28am UTC](https://discuss.elastic.co/t/what-will-happen-if-elasticsearch-all-node-goes-down-did-we-loose-all-data-in-this-case/265923/5 "2021-03-02T10:28:14Z")

</div>

@dadoonet Ok thanks, I will go through all above mentioned points.

---

<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: [March 30, 2021, 10:28am UTC](https://discuss.elastic.co/t/what-will-happen-if-elasticsearch-all-node-goes-down-did-we-loose-all-data-in-this-case/265923/6 "2021-03-30T10:28:37Z")

</div>

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