# Indices Folder inside Backup not cleaning up

**URL:** <https://discuss.elastic.co/t/indices-folder-inside-backup-not-cleaning-up/328902>\
**Category:** Elasticsearch\
**Tags:** snapshot-and-restore\
**Created:** [March 30, 2023, 8:25am UTC](https://discuss.elastic.co/t/indices-folder-inside-backup-not-cleaning-up/328902 "2023-03-30T08:25:09Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![DVoss2](https://avatars.discourse-cdn.com/v4/letter/d/3da27b/32.png) [@DVoss2](https://discuss.elastic.co/u/DVoss2)\
**Post date:** [March 30, 2023, 8:25am UTC](https://discuss.elastic.co/t/indices-folder-inside-backup-not-cleaning-up/328902/1 "2023-03-30T08:25:09Z")

</div>

Hi!

We are creating daily backups with:  
curl -u elastic: -X PUT 127.0.0.1:9200/\_snapshot/backup/snapshot-$snapdate?wait\_for\_completion=true  
and delete older ones with  
curl -u elastic: -X DELETE "127.0.0.1:9200/\_snapshot/backup/snapshot-$del\_date?pretty"

There is a folder called indices which grows w/o any limits.

What is the purpose of that folder?  
Can/shall we delete entries there manually?  
Or so we need to modify the deletion script?

Thanks a lot!

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [March 30, 2023, 9:01pm UTC](https://discuss.elastic.co/t/indices-folder-inside-backup-not-cleaning-up/328902/2 "2023-03-30T21:01:11Z")

</div>

Welcome to our community! 😃

Unless this is causing issues I wouldn't manually change anything in the directory as it's likely to break your backups. If it is causing issues then perhaps you could share some more information.

---

<div class="post-metadata">

**Author:** ![DVoss2](https://avatars.discourse-cdn.com/v4/letter/d/3da27b/32.png) [@DVoss2](https://discuss.elastic.co/u/DVoss2)\
**Post date:** [April 4, 2023, 1:16pm UTC](https://discuss.elastic.co/t/indices-folder-inside-backup-not-cleaning-up/328902/3 "2023-04-04T13:16:49Z")

</div>

Hi Mark,

thanks! Unf it is causing problems. We have 500 GB av. of which 400 are occupied with that indices and it's subfolders. Looks like this is not cleaned up with the deletion of old backups. The directories in there are several years old.  
Maybe something went wrong on the past, anyway we need to clean it up.  
Any idea? Otherwise we will delete everything and start from scratch.  
Thanks a lot!

---

<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:** [May 2, 2023, 1:17pm UTC](https://discuss.elastic.co/t/indices-folder-inside-backup-not-cleaning-up/328902/4 "2023-05-02T13:17:37Z")

</div>

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