es设置index.max_result_window(就是from+size,默认大小10000),可通过如下方式修改:
curl -XPUT 192.168.40.31:9200/datasmart/_settings -d '{ "index.max_result_window" :"1000000"}'
成功返回
{"acknowledged":true}
这个请求只会对datasmart这个索引起作用,如果是设置所有索引,把datasmart改成_all即可
查询当前max_result_window把PUT改成GET,如:
curl -XGET 192.168.40.31:9200/datasmart/_settings
返回:
{ "datasmart": { "settings": { "index": { "number_of_shards": "3", "provided_name": "datasmart", "max_result_window": "1000000", "creation_date": "1506303097464", "analysis": { "analyzer": { "default": { "type": "smartcn" } } }, "number_of_replicas": "1", "uuid": "84ufzn8nQ1-InuxYGHj_IA", "version": { "created": "5050199" } } } } }
这个设置是索引层的,即便是使用_all设置了,看日志也是对逐个索引加这个配置,后续新加的索引,max_result_window默认还是1w
标签:max,索引,window,result,设置,datasmart,es From: https://www.cnblogs.com/chenzhi2023/p/17042877.html