通过curl 查看es和调整配置
作者:互联网
调整集群的日志级别
curl -X PUT http://192.168.0.10:9201/_cluster/settings -H 'Content-Type: application/json' -d @debug.json
#调整到trace级别,下面是debug.json内容
{
"transient": {
"logger.org.elasticsearch.transport": "TRACE"
}
}
查看集群的setting
curl http://192.168.0.10:9201/_cluster/settings\?pretty
调整索引副本数
curl -X PUT http://192.168.0.10:9201/_settings -H 'Content-Type: application/json' -d '{"index":{"number_of_replicas":"0"}}'
#将索引的副本调整为0,这里是对所有索引生效
查看每个索引的settings
curl http://192.168.0.10:9201/_settings\?pretty
查看集群的健康情况
curl http://192.168.0.10:9201/_cluster/health\?pretty
标签:http,查看,settings,192.168,0.10,9201,curl,es 来源: https://www.cnblogs.com/aiverhua/p/16666881.html