# Backups with Curator

**URL:** <https://discuss.elastic.co/t/backups-with-curator/202509>\
**Category:** Elasticsearch\
**Tags:** curator\
**Created:** [October 7, 2019, 9:20am UTC](https://discuss.elastic.co/t/backups-with-curator/202509 "2019-10-07T09:20:53Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![dawid](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dawid/32/46548_2.png) [@dawid](https://discuss.elastic.co/u/dawid)\
**Post date:** [October 7, 2019, 9:20am UTC](https://discuss.elastic.co/t/backups-with-curator/202509/1 "2019-10-07T09:20:53Z")

</div>

Hi,

I am doing a monthly backups of indices (backing up everything older than a month to a backup repository) and then deleting those indices from Elasticsearch using Curator snapshot and delete indices actions.

My question is whether there is a way to execute deleting indices action only if snapshot action has completed successfully? I wouldn't want to delete indices from Elasticsearch if snapshot of those has failed. This is running on Windows environment.

Thank you!

---

<div class="post-metadata">

**Author:** ![theuntergeek](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/theuntergeek/32/44961_2.png) [@theuntergeek](https://discuss.elastic.co/u/theuntergeek)\
**Post date:** [October 17, 2019, 6:23pm UTC](https://discuss.elastic.co/t/backups-with-curator/202509/2 "2019-10-17T18:23:00Z")

</div>

Not yet, but it would be an interesting feature to add as a filter: index exists in named or most recent snapshot, with status SUCCESS.

Would you mind adding that as a feature request at [https://github.com/elastic/curator](https://github.com/elastic/curator) ?

---

<div class="post-metadata">

**Author:** ![Steve\_Stonebraker](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/steve_stonebraker/32/57198_2.png) [@Steve\_Stonebraker](https://discuss.elastic.co/u/Steve_Stonebraker)\
**Post date:** [November 5, 2019, 4:20pm UTC](https://discuss.elastic.co/t/backups-with-curator/202509/3 "2019-11-05T16:20:43Z")

</div>

Based on what I'm reading [here](https://github.com/elastic/curator/issues/1192) you can have curator backup your indexes in step1 (set _continue\_if\_execption: False_) and delete your indexes in step2.

I _think_ Curator will raise an exception on a failed snapshot (in step 1) and not execute step 2 (delete).

@theuntergeek you announced this fix [here](https://github.com/elastic/curator/issues/1192#issuecomment-390804430). Am I interpreting it correctly?

---

<div class="post-metadata">

**Author:** ![theuntergeek](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/theuntergeek/32/44961_2.png) [@theuntergeek](https://discuss.elastic.co/u/theuntergeek)\
**Post date:** [November 5, 2019, 4:40pm UTC](https://discuss.elastic.co/t/backups-with-curator/202509/4 "2019-11-05T16:40:20Z")

</div>

Yes, if using Curator 5.5.3 or later.

---

<div class="post-metadata">

**Author:** ![Steve\_Stonebraker](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/steve_stonebraker/32/57198_2.png) [@Steve\_Stonebraker](https://discuss.elastic.co/u/Steve_Stonebraker)\
**Post date:** [November 5, 2019, 4:49pm UTC](https://discuss.elastic.co/t/backups-with-curator/202509/5 "2019-11-05T16:49:27Z")

</div>

Awesome, thank you!

---

<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 3, 2019, 4:49pm UTC](https://discuss.elastic.co/t/backups-with-curator/202509/6 "2019-12-03T16:49:31Z")

</div>

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