在停止不用的es节点后,集群出现了红色状态,提示有10 unassigned shards。
查看出未分配的shard
curl -s "http://localhost:9200/_cat/shards" | grep UNASSIGNED.shield_audit_log-2017.03.15 4 p UNASSIGNED .shield_audit_log-2017.03.15 4 r UNASSIGNED .shield_audit_log-2017.03.15 1 p UNASSIGNED .shield_audit_log-2017.03.15 1 r UNASSIGNED .shield_audit_log-2017.03.15 2 p UNASSIGNED .shield_audit_log-2017.03.15 2 r UNASSIGNED .shield_audit_log-2017.03.15 3 p UNASSIGNED .shield_audit_log-2017.03.15 3 r UNASSIGNED .shield_audit_log-2017.03.15 0 p UNASSIGNED .shield_audit_log-2017.03.15 0 r UNASSIGNED
删除索引
curl -XDELETE 'http://localhost:9200/.shield_audit_log-*'