Elasticsearch集群状态查看常用指令

cat api使用

curl http://localhost:9200/_cat?help

=^.^=

/_cat/allocation

/_cat/shards

/_cat/shards/{index}

/_cat/master

/_cat/nodes

/_cat/indices

/_cat/indices/{index}

/_cat/segments

/_cat/segments/{index}

/_cat/count

/_cat/count/{index}

/_cat/recovery

/_cat/recovery/{index}

/_cat/health

/_cat/pending_tasks

/_cat/aliases

/_cat/aliases/{alias}

/_cat/thread_pool

/_cat/plugins

/_cat/fielddata

/_cat/fielddata/{fields}

 

/_cat/nodes?help 查看帮助参数

?v 输出列名

 

集群状态

curl localhost:9200/_cluster/health

curl localhost:9200/_cluster/state

curl localhost:9200/_cluster/settings

curl localhost:9200/_cluster/pending_tasks

 

节点状态

curl localhost:9200/_cat/nodes?v

curl localhost:9200/_nodes

curl localhost:9200/_nodes/stats

curl localhost:9200/_nodes/hot_threads

curl localhost:9200/_nodes/node-1/hot_threads

 

 

索引状态

curl localhost:9200/_cat/indices?v

curl localhost:9200/ _all?pretty

curl localhost:9200/_all/_stats

健康状态

curl localhost:9200/_cluster/health?pretty&level=indices

查看单个索引状态

curl localhost:9200/index_name/_stats

curl localhost:9200/index_name/_count

#查看mapping逻辑结构

curl localhost:9200/index_name/_mapping

 

查看物理结构

curl localhost:9200/index_name/_search_shards

curl localhost:9200/index_name/_segments

 

分片状态

curl localhost:9200/_cat/shards?help

curl localhost:9200/_cat/shards?v&h=index,shard,state,docs,store,ip,unassigned.reason,unassigned.details

 

查看线程池

curl localhost:9200/_cat/thread_pool/?v

 

查看分片分配状态

curl localhost:9200/_cluster/allocation/explain?pretty

你可能感兴趣的:(ElasticSearch)