# How to restart a data node that was stopped for a long time

**URL:** <https://discuss.elastic.co/t/how-to-restart-a-data-node-that-was-stopped-for-a-long-time/157675>\
**Category:** Elasticsearch\
**Created:** [November 21, 2018, 10:14am UTC](https://discuss.elastic.co/t/how-to-restart-a-data-node-that-was-stopped-for-a-long-time/157675 "2018-11-21T10:14:13Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![mahn](https://avatars.discourse-cdn.com/v4/letter/m/c2a13f/32.png) [@mahn](https://discuss.elastic.co/u/mahn)\
**Post date:** [November 21, 2018, 10:14am UTC](https://discuss.elastic.co/t/how-to-restart-a-data-node-that-was-stopped-for-a-long-time/157675/1 "2018-11-21T10:14:13Z")

</div>

We plan to restart a data note that was stopped for a long time ( \> 20 days).  
Cluster version is 6.4.1 and it is in green state.  
Can we simply restart elasticsearch on the node or should we perform some operations before?

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [November 21, 2018, 11:37am UTC](https://discuss.elastic.co/t/how-to-restart-a-data-node-that-was-stopped-for-a-long-time/157675/2 "2018-11-21T11:37:58Z")

</div>

You can simply restart the node. However, there is a risk that this node will contain shards from indices that were deleted and have fallen out of the [index graveyard](https://www.elastic.co/guide/en/elasticsearch/reference/current/misc-cluster.html#cluster-max-tombstones) of 500 indices (by default). If so then when the node is restarted those indices will be treated as dangling indices, and imported, which probably isn't what you wanted to happen. You'd have to watch the logs and delete any indices that are so imported.

If your cluster is green and you're not interested in recovering any data that was on the stopped node then I would start afresh: simply empty its data directory before starting it again.

---

<div class="post-metadata">

**Author:** ![mahn](https://avatars.discourse-cdn.com/v4/letter/m/c2a13f/32.png) [@mahn](https://discuss.elastic.co/u/mahn)\
**Post date:** [November 21, 2018, 5:02pm UTC](https://discuss.elastic.co/t/how-to-restart-a-data-node-that-was-stopped-for-a-long-time/157675/3 "2018-11-21T17:02:55Z")

</div>

Thank you David.  
I wasn't sure if the old indices would have been imported with potentially a lof of missing shards on the indices that were deleted during the time the node was stopped.  
With that knowledge I will start the node afresh with empty data.

---

<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 19, 2018, 9:06pm UTC](https://discuss.elastic.co/t/how-to-restart-a-data-node-that-was-stopped-for-a-long-time/157675/5 "2018-12-19T21:06:13Z")

</div>

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