How to configure beat to automatically rotate indices without ILM (7.9.1)

I am trying to implement an automatic indices rollover based on their size while ILM is disabled.
So, in beats configuration yml (e.g. metricbeat.yml) I specified the following:

setup.ilm.enabled: false
output.elasticsearch.index: "metricbeat-000001" "template_metricbeat"
setup.template.pattern: "metricbeat-*"
setup.template.type: "index"
setup.template.overwrite: "false"
setup.template.enabled: true

After starting the metricbeat, I created an alias with is_write_index=true for the index that was just created (metricbeat-000001). After running a rollover on the alias, a new index was created (metricbeat-000002) with is_write_index=true and the old index received is_write_index=false as expected. However, the metricbeat continued to write to metricbeat-000001 and not metricbeat-000002 . How do I make metricbeat to write to the relevant alias and not the original index? What am I missing?

Can I ask why you aren't using ILM?

Use the alias name in output.elasticsearch.index.

Assigning the alias name to output.elasticsearch.index was one of the first things I tried and I was quite surprised when ES created an index with the same name as the alias defined in output.elasticsearch.index. Of course I did not get what I wanted as such an index can't be rolled over at all (not matching -d+ pattern at the end of the name).

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