# Deleting all beats indices with Curator

**URL:** <https://discuss.elastic.co/t/deleting-all-beats-indices-with-curator/58464>\
**Category:** Beats\
**Created:** [August 19, 2016, 1:52pm UTC](https://discuss.elastic.co/t/deleting-all-beats-indices-with-curator/58464 "2016-08-19T13:52:41Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Diggy](https://avatars.discourse-cdn.com/v4/letter/d/e99b99/32.png) [@Diggy](https://discuss.elastic.co/u/Diggy)\
**Post date:** [August 19, 2016, 1:52pm UTC](https://discuss.elastic.co/t/deleting-all-beats-indices-with-curator/58464/1 "2016-08-19T13:52:41Z")

</div>

Hope this is the right place to post this:

I've installed Curator 4.0.1, and am using it to delete indices older than 14 days. It works fine if I'm only trying to delete a single index like logstash or filebeat. However,I'm trying to customize the example delete\_indices.yml to delete my filebeat, packetbeat, and topbeat indices in one pass. But, I can't fine the right directive to accomplish that. Here's what the file looks like:

actions:  
1:  
action: delete\_indices  
description: \>-  
Delete indices older than 14 days (based on index name), for beat-  
prefixed indices. Ignore the error if the filter does not result in an  
actionable list of indices (ignore\_empty\_list) and exit cleanly.  
options:  
ignore\_empty\_list: False  
timeout\_override:  
continue\_if\_exception: False  
disable\_action: False  
filters:  
- filtertype: pattern  
kind:  
value:  
exclude:  
- filtertype: age  
source: name  
direction: older  
timestring: '%Y.%m.%d'  
unit: days  
unit\_count: 14  
exclude: False

It's the filters "kind" and "value" that I can't seem to get right. Help would, as always, be appreciated.

---

<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:** [August 19, 2016, 2:37pm UTC](https://discuss.elastic.co/t/deleting-all-beats-indices-with-curator/58464/2 "2016-08-19T14:37:07Z")

</div>

You might try `kind: regex` and have a `value: '^.*beat-.*$'` to filter for indices with `beat-` in them.

Be sure to use the `--dry-run` flag to test before acting on it, to make sure it doesn't do something you don't want.

Also, Curator 4.0.6 is out now, with many bug fixes since 4.0.1.

---

<div class="post-metadata">

**Author:** ![Diggy](https://avatars.discourse-cdn.com/v4/letter/d/e99b99/32.png) [@Diggy](https://discuss.elastic.co/u/Diggy)\
**Post date:** [August 19, 2016, 4:13pm UTC](https://discuss.elastic.co/t/deleting-all-beats-indices-with-curator/58464/3 "2016-08-19T16:13:21Z")

</div>

Thanks, Aaron, that worked a treat! I very much appreciate the support I get in all of the Elastic forums - my issues get resolved, and I learn a great deal, too.

---

<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 9, 2016, 1:52pm UTC](https://discuss.elastic.co/t/deleting-all-beats-indices-with-curator/58464/4 "2016-09-09T13:52:43Z")

</div>

This topic was automatically closed after 21 days. New replies are no longer allowed.
