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

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 ??

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
1 Like

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 ??

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:

2 Likes

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

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