# Find Index name associated with ES/data folder

**URL:** <https://discuss.elastic.co/t/find-index-name-associated-with-es-data-folder/146586>\
**Category:** Elasticsearch\
**Created:** [August 29, 2018, 9:37pm UTC](https://discuss.elastic.co/t/find-index-name-associated-with-es-data-folder/146586 "2018-08-29T21:37:14Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![shine](https://avatars.discourse-cdn.com/v4/letter/s/77aa72/32.png) [@shine](https://discuss.elastic.co/u/shine)\
**Post date:** [August 29, 2018, 9:37pm UTC](https://discuss.elastic.co/t/find-index-name-associated-with-es-data-folder/146586/1 "2018-08-29T21:37:14Z")

</div>

I had to delete all my data from my elasticsearch/data/nodes/\* folder because index "cust\_name\_abc" had a transaction log read error. Which stopped my entire ELK stack.

In the future how do I find the matching elasticsearch/data/nodes/xxx folder for "cust\_name\_abc"

The data folder had folder names with random number & letters.

Thanks

---

<div class="post-metadata">

**Author:** ![Bernt\_Rostad](https://avatars.discourse-cdn.com/v4/letter/b/3ab097/32.png) [@Bernt\_Rostad](https://discuss.elastic.co/u/Bernt_Rostad)\
**Post date:** [August 30, 2018, 1:47pm UTC](https://discuss.elastic.co/t/find-index-name-associated-with-es-data-folder/146586/2 "2018-08-30T13:47:39Z")

</div>

> [@shine](#):
>
> I had to delete all my data from my elasticsearch/data/nodes/\* folder

Removing files from the Elasticsearch **path.data** directory is quite dangerous and not a recommended way of cleaning up bad data, the only times I've done so is when I've done a clean install on an old Elasticsearch node - then I remove the entire data directory to create a fresh one.

If you need to get rid of a faulty index, just use the [Delete Index](https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-delete-index.html) mechanism - it allows you to delete one or several indices via a curl command (or from Kibana). For instance

`curl -X DELETE "localhost:9200/facebook-*"`

will delete all indices with names starting with "facebook-". This is quick and much safer than removing files from the data directory.

---

<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:** [September 27, 2018, 1:47pm UTC](https://discuss.elastic.co/t/find-index-name-associated-with-es-data-folder/146586/3 "2018-09-27T13:47:42Z")

</div>

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