ILM - custom index name with rollover_alias is creating new index templates

In my Beats, I have settings as follow:

setup.template.name: "metricbeat"
setup.template.pattern: "metricbeat-*"

setup.ilm.rollover_alias: "metricbeat-%{[agent.version]}-hkhqdev"

Index is created correctly as metricbeat-7.5.2-hkhqdev-2020.02.11-000001
Existing Lifecycle Policy metricbeat-7.5.2 is correctly attached to it.

But it is creating index template for each index metricbeat-7.5.2-hkhqdev-*, while I would expect it would be using the common one, which already exists metricbeat-7.5.2. Why are my setup.template settings ignored.

Logs from beats:

2020-02-11T23:22:51.671+0800 INFO [index-management] idxmgmt/std.go:269 ILM policy successfully loaded.
2020-02-11T23:22:51.672+0800 INFO [index-management] idxmgmt/std.go:408 Set setup.template.name to '{metricbeat-7.5.2-hkhqdev {now/d}-000001}' as ILM is enabled.
2020-02-11T23:22:51.672+0800 INFO [index-management] idxmgmt/std.go:413 Set setup.template.pattern to 'metricbeat-7.5.2-hkhqdev-*' as ILM is enabled.
2020-02-11T23:22:51.672+0800 INFO [index-management] idxmgmt/std.go:447 Set settings.index.lifecycle.rollover_alias in template to {metricbeat-7.5.2-hkhqdev {now/d}-000001} as ILM is enabled.
2020-02-11T23:22:51.672+0800 INFO [index-management] idxmgmt/std.go:451 Set settings.index.lifecycle.name in template to {metricbeat-7.5.2 {"policy":{"phases":{"hot":{"actions":{"rollover":{"max_age":"30d","max_size":"50gb"}}}}}}} as ILM is enabled.
2020-02-11T23:22:51.954+0800 INFO template/load.go:109 Try loading template metricbeat-7.5.2-hkhqdev to Elasticsearch
2020-02-11T23:22:52.761+0800 INFO template/load.go:101 template with name 'metricbeat-7.5.2-hkhqdev' loaded.

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