# Deleting indices with shadow replicas

**URL:** <https://discuss.elastic.co/t/deleting-indices-with-shadow-replicas/28261>\
**Category:** Elasticsearch\
**Created:** [August 28, 2015, 5:11pm UTC](https://discuss.elastic.co/t/deleting-indices-with-shadow-replicas/28261 "2015-08-28T17:11:22Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![natefox](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/natefox/32/44821_2.png) [@natefox](https://discuss.elastic.co/u/natefox)\
**Post date:** [August 28, 2015, 5:11pm UTC](https://discuss.elastic.co/t/deleting-indices-with-shadow-replicas/28261/1 "2015-08-28T17:11:22Z")

</div>

Normally when we delete indicies, the actual data on disk is deleted as well. However, when we delete the indices that are using shadow replicas, the data is not actually being removed from disk. Is this on purpose?  
We're running 1.7.1.

---

<div class="post-metadata">

**Author:** ![dakrone](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dakrone/32/23351_2.png) [@dakrone](https://discuss.elastic.co/u/dakrone)\
**Post date:** [August 29, 2015, 11:50pm UTC](https://discuss.elastic.co/t/deleting-indices-with-shadow-replicas/28261/2 "2015-08-29T23:50:56Z")

</div>

Hi Natefox,

I just tried reproducing this locally, and when I deleted the index it also deleted the data on disk in the shared path. Can you give me a listing of the files that are still around after deleting the index, and the steps you are taking when creating/deleting the index?

---

<div class="post-metadata">

**Author:** ![natefox](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/natefox/32/44821_2.png) [@natefox](https://discuss.elastic.co/u/natefox)\
**Post date:** [August 31, 2015, 6:51pm UTC](https://discuss.elastic.co/t/deleting-indices-with-shadow-replicas/28261/3 "2015-08-31T18:51:19Z")

</div>

Sorry, I missed a vital step: if you close the index first and then delete it - the shadow copy still remains but if you do the same thing to a non-shadow copy index the data is actually deleted off disk.

---

<div class="post-metadata">

**Author:** ![dakrone](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dakrone/32/23351_2.png) [@dakrone](https://discuss.elastic.co/u/dakrone)\
**Post date:** [September 3, 2015, 11:49am UTC](https://discuss.elastic.co/t/deleting-indices-with-shadow-replicas/28261/4 "2015-09-03T11:49:02Z")

</div>

Okay, I am able to reproduce this now, will continue the discussion in [https://github.com/elastic/elasticsearch/issues/13297](https://github.com/elastic/elasticsearch/issues/13297)

Thanks!

---

<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 5, 2017, 11:52pm UTC](https://discuss.elastic.co/t/deleting-indices-with-shadow-replicas/28261/5 "2017-07-05T23:52:16Z")

</div>


