#!/bin/bash DATE=`date -d "2 days ago" +%Y.%m.%d` index=" linux39-nginx-acceslog tomcat-accesslog-2.105 tomcat-accesslog-2.105 tomcat-accesslog-2.104 tcplog-2.107 syslog-linux39-2.107 " for NAME in ${index};do FULL_NAME="$NAME-$DATE" echo $FULL_NAME #echo linux39-nginx-errorlog-2020.03.18 curl -XDELETE http://172.31.7.248:9200/${FULL_NAME} done
标签:index,FULL,NAME,tomcat,accesslog,linux39,集群,ES From: https://www.cnblogs.com/Yuanbangchen/p/17024333.html