# Filtering indices with index.lifecycle.name removing from list

**URL:** <https://discuss.elastic.co/t/filtering-indices-with-index-lifecycle-name-removing-from-list/233730>\
**Category:** Elasticsearch\
**Created:** [May 21, 2020, 11:41am UTC](https://discuss.elastic.co/t/filtering-indices-with-index-lifecycle-name-removing-from-list/233730 "2020-05-21T11:41:42Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Adriann](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/adriann/32/77780_2.png) [@Adriann](https://discuss.elastic.co/u/Adriann)\
**Post date:** [May 21, 2020, 11:41am UTC](https://discuss.elastic.co/t/filtering-indices-with-index-lifecycle-name-removing-from-list/233730/1 "2020-05-21T11:41:42Z")

</div>

Hello,

While I was testing the curator I encounter the below problem.

```
Curator Config
       Preformatted textclient:
      hosts:
        - 127.0.0.1
      port: 9200
      http_auth: "elastic:elastic"
      url_prefix:
      use_ssl: False
      certificate:
      client_cert:
      client_key:
      ssl_no_validate: False
      timeout: 30
      master_only: False
    logging:
      loglevel: DEBUG
      logfile: /var/log/curator.log
      logformat: default
      blacklist: ['elasticsearch', 'urllib3']

```

Action file:

```
    actions:
      1:
        action: shrink
        description: >-
          Shrink logstash indices older than 1 days on the node with the most
          available space, excluding the node named 'not_this_node'.
          Delete each source index after successful shrink, then reroute the shrunk
          index with the provided parameters.
        options:
          disable_action: False
          ignore_empty_list: True
          allow_ilm_indices: False
          shrink_node: DETERMINISTIC
          node_filters:
            permit_masters: False
            exclude_nodes: ['not_this_node']
          number_of_shards: 1
          number_of_replicas: 1
          shrink_prefix:
          shrink_suffix: '-shrink'
          delete_after: True
          post_allocation:
            allocation_type: include
            key: node_tag
            value: cold
          wait_for_active_shards: 1
          extra_settings:
            settings:
              index.codec: best_compression
          wait_for_completion: True
          wait_for_rebalance: True
          wait_interval: 9
          max_wait: -1
        filters:
        - filtertype: pattern
          kind: prefix
          value: filebeat-
        - filtertype: age
          source: creation_date
          direction: older
          unit: minutes
          unit_count: 15

```

Logs:

```
2020-05-21 13:30:44,626 DEBUG curator.validators.SchemaCheck __init__ :27 "filter" config: {'filtertype': 'ilm'}
2020-05-21 13:30:44,626 DEBUG curator.indexlist iterate_filters:1234 Parsed filter args: {'filtertype': 'ilm'}
2020-05-21 13:30:44,626 DEBUG curator.indexlist filter_ilm:1180 Filtering indices with index.lifecycle.name
2020-05-21 13:30:44,643 DEBUG curator.indexlist __not_actionable:39 Index filebeat-2020.05.21-000002 is not actionable, removing from list.
2020-05-21 13:30:44,643 DEBUG curator.indexlist __excludify:58 Removed from actionable list: filebeat-2020.05.21-000002 has index.lifecycle.name filebeat
2020-05-21 13:30:44,643 DEBUG curator.indexlist __not_actionable:39 Index filebeat-2020.05.20-000001 is not actionable, removing from list.
2020-05-21 13:30:44,643 DEBUG curator.indexlist __excludify:58 Removed from actionable list: filebeat-2020.05.20-000001 has index.lifecycle.name filebeat
2020-05-21 13:30:44,643 DEBUG curator.indexlist __not_actionable:39 Index filebeat-netflow-2020.05.21t11 is not actionable, removing from list.
2020-05-21 13:30:44,643 DEBUG curator.indexlist __excludify:58 Removed from actionable list: filebeat-netflow-2020.05.21t11 has index.lifecycle.name filebeat
2020-05-21 13:30:44,643 DEBUG curator.indexlist __not_actionable:39 Index filebeat-7.6.2-2020.05.18-000001 is not actionable, removing from list.
2020-05-21 13:30:44,643 DEBUG curator.indexlist __excludify:58 Removed from actionable list: filebeat-7.6.2-2020.05.18-000001 has index.lifecycle.name filebeat
2020-05-21 13:30:44,643 DEBUG curator.indexlist __not_actionable:39 Index filebeat-7.6.2-2020.05.21-000002 is not actionable, removing from list.
2020-05-21 13:30:44,643 DEBUG curator.indexlist __excludify:58 Removed from actionable list: filebeat-7.6.2-2020.05.21-000002 has index.lifecycle.name filebeat
2020-05-21 13:30:44,643 DEBUG curator.indexlist __not_actionable:39 Index filebeat-cisco-2020.05.21 is not actionable, removing from list.
2020-05-21 13:30:44,643 DEBUG curator.indexlist __excludify:58 Removed from actionable list: filebeat-cisco-2020.05.21 has index.lifecycle.name filebeat
2020-05-21 13:30:44,644 DEBUG curator.indexlist __not_actionable:39 Index filebeat-cisco-2020.05.21t12 is not actionable, removing from list.
2020-05-21 13:30:44,644 DEBUG curator.indexlist __excludify:58 Removed from actionable list: filebeat-cisco-2020.05.21t12 has index.lifecycle.name filebeat
2020-05-21 13:30:44,644 DEBUG curator.indexlist __not_actionable:39 Index filebeat-netflow-2020.05.21t10 is not actionable, removing from list.
2020-05-21 13:30:44,644 DEBUG curator.indexlist __excludify:58 Removed from actionable list: filebeat-netflow-2020.05.21t10 has index.lifecycle.name filebeat
2020-05-21 13:30:44,644 DEBUG curator.indexlist __not_actionable:39 Index filebeat-cisco-2020.05.21t13 is not actionable, removing from list.
2020-05-21 13:30:44,644 DEBUG curator.indexlist __excludify:58 Removed from actionable list: filebeat-cisco-2020.05.21t13 has index.lifecycle.name filebeat
2020-05-21 13:30:44,644 DEBUG curator.actions.shrink _merge_extra_settings:2049 Adding extra_settings to shrink body: {'settings': {'index.codec': 'best_compression'}}

```

but it does not work because of ILM filter

How can I disable this filter?

---

<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:** [May 21, 2020, 3:12pm UTC](https://discuss.elastic.co/t/filtering-indices-with-index-lifecycle-name-removing-from-list/233730/2 "2020-05-21T15:12:27Z")

</div>

The clue is already in your configuration:

> [@Adriann](#):
>
> ```auto
> allow_ilm_indices: False
> 
> ```

Change that to `true` and this action will be good to go. This is described in [the official documentation](https://www.elastic.co/guide/en/elasticsearch/client/curator/5.8/ilm-and-curator.html).

---

<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:** [June 18, 2020, 3:12pm UTC](https://discuss.elastic.co/t/filtering-indices-with-index-lifecycle-name-removing-from-list/233730/3 "2020-06-18T15:12:27Z")

</div>

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