How to delete elastic search indices older than 30 days using dev tool commands

Viewed 3619

I want to delete kibana indices that are older than 30 days from today using kibana dev tools.

1 Answers

You can simply use the Index life cycle management to automate it.

EDIT You can use the http://es-host:9200/_cat/indices?h=index,creation.date.string to find the indices creation time of all indices in your cluster, once you have all the indices, you can delete them using the delete indices API.

Related