ILM policy not working

Hi,
I am using elk version 8.0.0 in windows OS. There is totally 3 elk nodes 2 logstash and 1 kibana nodes .
The ILM is not working based on the duration i set (ex:5mints,the data is not getting deleted).I have created ILM template and assigned metricbeat 8.0.0 or metricbeat-*(tried with both) but data deletion is not happening.
There is no error in all 3 Elasticsearch nodes logs and in kibana also and it's showing success while i click on the save policy.

Below is the source code which i implemented from my end (which is not working):
PUT _ilm/policy/metricbeat
{
"policy": {
"phases": {
"hot": {
"min_age": "0ms",
"actions": {
"set_priority": {
"priority": 100
}
}
},
"delete": {
"min_age": "5m",
"actions": {
"delete": {
"delete_searchable_snapshot": true
}
}
}
}
}
}

Hello @jisha

if you are applying ILM for existing indices

Hi Sudhagar,
I want to apply ILM for the upcoming indices cases.

Hello @jisha

The below are the steps: (old method)
1.Create policy
2.Create index template
3.Add policy to index template

the new method is to try in kibana where we have the rollover of data from hot,warm and cold in UI , post which you would be getting the code

@jisha Could you please provide update on this topic

@sudhagar_ramesh The issue got resolved . I added below POST remove (executed it first)and PUT command (Run it).
POST /_ilm/remove # to remove ILM policy and reapply it
PUT mylogs-pre-ilm*/_settings {"index": {"lifecycle": {"name": "mylogs_policy_existing"}}}

1 Like

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