# Trouble getting ILM to work for externally created index

**URL:** <https://discuss.elastic.co/t/trouble-getting-ilm-to-work-for-externally-created-index/268766>\
**Category:** Elasticsearch\
**Tags:** ilm-index-lifecycle-management\
**Created:** [March 30, 2021, 9:59am UTC](https://discuss.elastic.co/t/trouble-getting-ilm-to-work-for-externally-created-index/268766 "2021-03-30T09:59:33Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![runtman](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/runtman/32/18136_2.png) [@runtman](https://discuss.elastic.co/u/runtman)\
**Post date:** [March 30, 2021, 9:59am UTC](https://discuss.elastic.co/t/trouble-getting-ilm-to-work-for-externally-created-index/268766/1 "2021-03-30T09:59:33Z")

</div>

Hello, I am using a kafka service from a supplier called Aiven, they have a connector which can push logs to elasticsearch.

They push the logs into a daily index called: `kafka-YYYY-MM-DD` .

Now I tried to create an index template, so I can use ILM with this.

```auto
    {
      "index": {
        "lifecycle": {
          "name": "Standard-Index",
          "rollover_alias": "kafka-*"
        },
        "mapping": {
          "total_fields": {
            "limit": "10000"
          }
        },
        "refresh_interval": "5s",
        "number_of_shards": "1",
        "number_of_replicas": "1"
      }
    }

```

This results in the error: ` "index.lifecycle.rollover_alias [kafka-*] does not point to index [kafka-2021-03-29]`

Now I have looked at lots of documents, some suggest dropping the date (I have no control of that), i've read the documents a fair few times now and also scanned these boards and can't really find an answer.

Does any one have any suggestion on how I can catch this index and make it fit for ILM?

---

<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:** [April 27, 2021, 10:00am UTC](https://discuss.elastic.co/t/trouble-getting-ilm-to-work-for-externally-created-index/268766/2 "2021-04-27T10:00:23Z")

</div>

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