Last updated 5 years ago
Was this helpful?
实时改变特定索引级别设置。
REST 方式 / _settings(更新所有索引) 或{index}/_settings更新一个(或多个)索引设置。请求的主体包括更新设置,例如:
/ _settings
{index}/_settings
{ "index" : { "number_of_replicas" : 4 } }
将副本的数量设置为4个。下面是一个curl的例子:
curl -XPUT 'localhost:9200/my_index/_settings' -d ' { "index" : { "number_of_replicas" : 4 } }'
可以在动态索引上动态更新的每个索引设置列表可以在索引模块()中找到。
在开始批量索引之前,使用:
curl -XPUT localhost:9200/test/_settings -d '{ "index" : { "refresh_interval" : "-1" } }'