设置现有的index的副本数量为0个。---集群健康值为yellow的解决办法
curl -u "elastic" -X PUT "10.13.30.168:9200/*/_settings" -H 'Content-Type: application/json' -d'
{
"index" : {
"number_of_replicas" : 0
}
}
'
设置新建的index副本数量为0个,(创建模板匹配所有index,并设置副本数量为0)
curl -u "elastic" -X PUT "10.6.80.249:9200/_template/template_log" -H 'Content-Type: application/json' -d'
{
"index_patterns" : ["*"],
"order" : 0,
"settings" : {
"number_of_replicas" : 0
}
}
'