Removing old indices in elasticsearch

后端 未结 9 2135
生来不讨喜
生来不讨喜 2020-12-07 21:12

I have the many of my logs indexed in logstash-Year-Week format. That is if i want to delete indices older than a few weeks, how can I achieve that in elasticsearch. Is ther

9条回答
  •  盖世英雄少女心
    2020-12-07 21:35

    curator_cli delete_indices --filter_list '{"filtertype":"none"}' 
    

    will delete all or filter:

     --filter_list '[{"filtertype":"age","source":"creation_date","direction":"older","unit":"days","unit_count":13},{"filtertype":"pattern","kind":"prefix","value":"logstash"}]'
    

提交回复
热议问题