elasticsearch 6.8 cluster命令官网文档
_cat命令/_cat 命令,可以查看所有的cat api?help参数,来查看返回的所有列字段及其它信息,示例/_cat/master?help?v参数,来显示详细的信息, 示例:/_cat/master?vh指定返回的列,示例:/_cat/nodes?h=ip,port,heapPercent,name/_cat/indices?bytes=kb&v'
time参数,单位有:d,h,m,s,ms,micros,nanossize参数,单位有:k,m,g,t,pbytes参数,单位有:b,kb,mb,gb,tb,pb/_cat/indices?bytes=kb&v&format=json&pretty
/_cat/indices?v&h=index,docs.count,store.size&bytes=kb&format=json&pretty&s=index,docs.count:desc| 描述 | 命令 | 示例 |
|---|---|---|
| 查看别名接口 | _cat/aliases | /_cat/aliases?v&h=alias,index |
| 查看分配资源接口 | _cat/allocation | |
| 查看文档个数接口 | _cat/count | |
| 查看字段分配情况接口 | _cat/fielddata | /_cat/fielddata?v&h=node,field,size |
| 查看健康状态接口 | _cat/health | /_cat/health?v&h=cluster,status |
| 查看索引信息接口 | _cat/indices | /_cat/indices/.monitoring*?v&h=index,health |
| 查看master信息接口 | _cat/master | /_cat/master?v |
| 查看nodes信息接口 | _cat/nodes | /_cat/nodes?v&h=ip,node.role,name,disk.avail |
| 查看正在挂起的任务接口 | _cat/pending_tasks | |
| 查看插件接口 | _cat/plugins | |
| 查看修复状态接口 | _cat/recovery | /_cat/recovery/.kibana?v&format=json&pretty |
| 查看线城池接口 | _cat/thread_pool | /_cat/thread_pool/bulk?v&format=json&pretty |
| 查看分片信息接口 | _cat/shards | /_cat/shards?v&format=json&pretty&s=index |
| 查看lucence的段信息接口 | _cat/segments | /_cat/segments/.kibana?v&format=json&pretty |
| 查看索引模板 | _cat/templates | /_cat/templates?v&format=json&pretty |
_cat/nodeshttp://localhost:9200/_cat/nodes?v&format=text&pretty

_cat/allocationhttp://localhost:9200/_cat/allocation?v&pretty

shards:分片个数
disk.indices:索引所占磁盘大小
disk.used:已用磁盘大小
disk.avail:可以使用磁盘大小
disk.total:磁盘总容量
disk.percent:磁盘使用百分比
host:主机名
ip:服务ip
node:节点名称
_cluster命令| 描述 | 命令 | 示例 |
|---|---|---|
| 查看集群健康状态接口 | _cluster/health | /_cluster/health?level=shards /_cluster/health/test1,test2 |
| 查看集群状况接口 | _cluster/state | /_cluster/state/_all/foo,bar /_cluster/state/metadata,routing_table?pretty |
| 查看集群统计信息接口 | _cluster/stats | /_cluster/stats?human&pretty |
| 查看集群挂起的任务接口 | _cluster/pending_tasks | /_cluster/pending_tasks |
| 集群重新路由操作 | _cluster/reroute | |
| 更新集群设置 | _cluster/settings | /_cluster/settings |
| 节点状态 | _nodes/stats | /_nodes/nodeId1,nodeId2/stats /_nodes/stats |
| 节点信息 | _nodes | /_nodes/nodeId1,nodeId2/info/jvm,process /_nodes/nodeId1,nodeId2/_all |
| 节点的热线程 | _nodes/hot_threads | /_nodes/nodeId1,nodeId2/hot_threads /_nodes/hot_threads |
注意:关闭节点的API已经删除
