es集群问题排查、常用命令、参数解析

一、常用命令

#1.集群健康状态
[wlsadmin@elastic-01~]$ curl -XGET "http://10.219.27.00:7116/_cluster/health?pretty"
{
   
   
cluster name":"cluster"
"status": "yellow",   #集群状态
"timed out" : false,
"number of nodes": 3,  #集群的节点数
"number_of data nodes": 3, #数据节点数
"active_primary_shards" : 8036,  #集群中所有活跃的主分片数
"active shards": 16082, #集群中所有活跃的分片数
"relocating shards": 0, #当前节点迁往其他节点的分片数量,通常为0,当有节点加入或者退出时该值会增加。
"initializing shards": 0, #正在初始化的分片
"unassigned shards": 10,  #未分配的分片数,通常为0,当有某个节点的副本分片丢失该值就会增加。
"delayed unassigned shards": 0,
"number of pending tasks": 0, 是指主节点创建索引并分配shards等任务,如果该指标数值一直未减小代表集群存在不稳定因素
"number of in flight fetch" :0,
"task max waiting in queue millis": 0,
"active shards percent as number" :99.93785732040766  #集群分片健康度,活跃分片数占总分片数比例。
}
 
说明:pending task只能由主节点来进行处理,这些任务包括创建索引并将shards分配给节点。

#2.集群状态信息
[wlsadmin@elastic-01~]$ curl -XGET "http://10.219.27.00:7116/_cluster/stats?pretty"
{
    "_nodes":{
    "total":3,
    "successful":3,
    "failed":0
    },
   "cluster name":"cluster"
   "timestamp": 1650958054278,
   "status": "yellow",
   "indices":{
     "count”:1612,  #索引总数
     "shards":{
   
   
       "total”:16082,  #分片总数
       "primaries”:8036, #主分片数量
       "replication”: 1.001244400199104
       "index":{
         "shards":{
            "min": 2,
            "max”:15,
            "avg”: 9.97642679900744
            },
            "docs”:{
   
   
          "count”: 6917866009,  #文档总数
          "deleted": 16940
          },
          "store":{
           "size in bytes”:7722541162072  #数据总存储容量
           "throttle time in millis": 0
           }"fielddata”:{
           "memory_size_in_bytes": 2400,
           "evictions”:0}"segments”:{
      "count”:182641, #段总数</
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值