删除test-log索引
curl -XDELETE "127.0.0.1:9200/test-log"
查看es的索引
http://127.0.0.1:9200/_cat/indices?v
定时清理三天前的索引数据脚本
#!/bin/bash
shijian=`date +%Y.%m.%d -d "3 days ago"`
curl -XDELETE "192.168.0.231:9200/filebeat-${shijian}"