1、[o.e.x.s.a.AuthenticationService] [node-client] Authentication of [elastic] was terminated by realm [reserved] - failed to authenticate user [elastic]
解决方案:使用cd命令切换到elasticsearch的bin目录(重点),然后使用 ./elasticsearch-setup-passwords auto 命令自动生成好几个默认用户和密码。
如果想手动生成密码,则使用 bin/elasticsearch-setup-passwords interactive 命令。
2、使用elasticsearch做分页查询时,当查询记录超过10000时报错
max_result_window:所要返回的数据量大小
PUT index_name/_settings
{
"index":{
"max_result_window":1000000
}
}