1.curl的常用命令
--查看健康状态
curl http://192.168.1.7:9201/_cat/health
1719646956 07:42:36 escluster1 green 3 3 91 42 0 0 0 0 - 100.0%
--查看较详细的健康状态
curl http://192.168.1.7:9201/_cat/health?v
epoch timestamp cluster status node.total node.data shards pri relo init unassign pending_tasks max_task_wait_time active_shards_percent
1719646974 07:42:54 escluster1 green 3 3 91 42 0 0 0 0 - 100.0%
--查看帮助。
curl http://192.168.1.7:9201/_cat/health?help
epoch | t,time | seconds since 1970-01-01 00:00:00
timestamp | ts,hms,hhmmss | time in HH:MM:SS
cluster | cl | cluster name
status | st | health status
node.total | nt,nodeTotal | total number of nodes
node.data | nd,nodeData | number of nodes that can store data
shards | t,sh,shards.total,shardsTotal | total number of shards
pri | p,shards.primary,shardsPrimary | number of primary shards
relo | r,shards.relocating,shardsRelocating | number of relocating nodes
init | i,shards.initializing,shardsInitializing | number of initializing nodes
unassign | u,shards.unassigned,shardsUnassigned | number of unassigned shards
pending_tasks | pt,pendingTasks | number of pending tasks
max_task_wait_time | mtwt,maxTaskWaitTime | wait time of longest task pending
active_shards_percent | asp,activeShardsPercent | active number of shards in percent
--查看节点分片情况
---v:表示查看详细信息。
--查看节点数据分布
curl http://192.168.1.7:9201/_cat/allocation
31 11.1mb 21.8gb 28.1gb 49.9gb 43 192.168.1.7 192.168.1.7 esdb-node-3
30 625.8kb 21.8gb 28.1gb 49.9gb 43 192.168.1.7 192.168.1.7 esdb-node-1
30 10.5mb 21.8gb 28.1gb 49.9gb 43 192.168.1.7 192.168.1.7 esdb-node-2
--查看节点数据分布详情
curl http://192.168.1.7:9201/_cat/allocation?v
shards disk.indices disk.used disk.avail disk.total disk.percent host ip node
30 648.2kb 21.8gb 28.1gb 49.9gb 43 192.168.1.7 192.168.1.7 esdb-node-1
31 11mb 21.8gb 28.1gb 49.9gb 43 192.168.1.7 192.168.1.7 esdb-node-3
30 10.5mb 21.8gb 28.1gb 49.9gb 43 192.168.1.7 192.168.1.7 esdb-node-2
--查看分片
curl http://192.168.1.7:9201/_cat/shards?v
xsq1 3 p STARTED 0 261b 192.168.1.7 esdb-node-2
xsq1 3 r STARTED 0 261b 192.168.1.7 esdb-node-1
xsq1 4 p STARTED 2 11.1kb 192.168.1.7 esdb-node-3
xsq1 4 r STARTED 2 11.1kb 192.168.1.7 esdb-node-2
xsq1 1 r STARTED 0 261b 192.168.1.7 esdb-node-2
xsq1 1 p STARTED 0 261b 192.168.1.7 esdb-node-1
xsq1 2 p STARTED 0 261b 192.168.1.7 esdb-node-3
xsq1 2 r STARTED 0 261b 192.168.1.7 esdb-node-2
xsq1 0 r STARTED 0 261b 192.168.1.7 esdb-node-3
xsq1 0 p STARTED 0 261b 192.168.1.7 esdb-node-1
xs1 0 r STARTED 1 5.6kb 192.168.1.7 esdb-node-3
xs1 0 p STARTED 1 5.6kb 192.168.1.7 esdb-node-1
myindex5 0 r STARTED 4 12.6kb 192.168.1.7 esdb-node-3
myindex5 0 p STARTED 4 12.6kb 192.168.1.7 esdb-node-1
test_index 0 r STARTED 1 6kb 192.168.1.7 esdb-node-2
test_index 0 p STARTED 1 6kb 192.168.1.7 esdb-node-1
myindex3 0 p STARTED 6 7.2kb 192.168.1.7 esdb-node-3
myindex3 0 r STARTED 6 7.2kb 192.168.1.7 esdb-node-2
myindex15 0 p STARTED 4 24.1kb 192.168.1.7 esdb-node-3
myindex15 0 r STARTED 4 24.1kb 192.168.1.7 esdb-node-2
shanghai 2 r STARTED 0 208b 192.168.1.7 esdb-node-3
shanghai 2 p STARTED 0 208b 192.168.1.7 esdb-node-2
shanghai 1 r STARTED 0 208b 192.168.1.7 esdb-node-2
shanghai 1 p STARTED 0 208b 192.168.1.7 esdb-node-1
shanghai 0 p STARTED 0 208b 192.168.1.7 esdb-node-3
shanghai 0 r STARTED 0 208b 192.168.1.7 esdb-node-1
--查看某个索引的分片
curl http://192.168.1.7:9201/_cat/shards/myindex3?v
index shard prirep state docs store ip node
myindex3 0 p STARTED 6 7.2kb 192.168.1.7 esdb-node-3
myindex3 0 r STARTED 6 7.2kb 192.168.1.7 esdb-node-2
--查看索引分片大小。
curl http://192.168.1.7:9201/_cat/shards/myindex5?bytes=k
myindex5 0 r STARTED 4 12 192.168.1.7 esdb-node-3
myindex5 0 p STARTED 4 12 192.168.1.7 esdb-node-1
-- 查看索引分片大小
curl http://192.168.1.7:9201/_cat/shards/myindex5?bytes=m
myindex5 0 r STARTED 4 0 192.168.1.7 esdb-node-3
myindex5 0 p STARTED 4 0 192.168.1.7 esdb-node-1
--查看master节点
curl http://192.168.1.7:9201/_cat/master
1M-5yVJyRHakKuwSYpXeNQ 192.168.1.7 192.168.1.7 esdb-node-3
--查看节点
curl http://192.168.1.7:9201/_cat/nodes?v
ip heap.percent ram.percent cpu load_1m load_5m load_15m node.role master name
192.168.1.7 44 64 4 0.12 0.30 0.41 dilmt - esdb-node-2
192.168.1.7 44 64 4 0.12 0.30 0.41 dilmt - esdb-node-1
192.168.1.7 39 64 4 0.12 0.30 0.41 dilmt * esdb-node-3
--节点属性
curl http://192.168.1.7:9201/_cat/nodeattrs?v
node host ip attr value
esdb-node-2 192.168.1.7 192.168.1.7 ml.machine_memory 16637493248
esdb-node-2 192.168.1.7 192.168.1.7 ml.max_open_jobs 20
esdb-node-2 192.168.1.7 192.168.1.7 xpack.installed true
esdb-node-2 192.168.1.7 192.168.1.7 transform.node true
esdb-node-1 192.168.1.7 192.168.1.7 ml.machine_memory 16637493248
esdb-node-1 192.168.1.7 192.168.1.7 ml.max_open_jobs 20
esdb-node-1 192.168.1.7 192.168.1.7 xpack.installed true
esdb-node-1 192.168.1.7 192.168.1.7 transform.node true
esdb-node-3 192.168.1.7 192.168.1.7 ml.machine_memory 16637493248
esdb-node-3 192.168.1.7 192.168.1.7 ml.max_open_jobs 20
esdb-node-3 192.168.1.7 192.168.1.7 xpack.installed true
esdb-node-3 192.168.1.7 192.168.1.7 transform.node true
--查看索引
curl http://192.168.1.7:9201/_cat/indices
green open myindex10 ADx7MMZYQDaVc5XX7LLgnA 3 2 0 0 1.8kb 624b
green open .kibana-event-log-7.9.2-000001 Cc8ZQFD1TSm4_MqVZMfw6w 1 1 1 0 11.2kb 5.6kb
green open xsq1 QMMGLwzsTJ2kdPc6QGmPmQ 5 1 2 0 24.2kb 12.1kb
green open xsq3 m_cSWmZaSaCErrrMBsNlHg 5 1 8 3 78.6kb 39.3kb
green open .apm-agent-configuration igmjyuW5Q_mbop6YWvtQGg 1 1 0 0 416b 208b
green open sspuuser SuCFW8I7RfWDPtD0xhsXJQ 3 1 11 0 42.7kb 21.3kb
green open myindex14 M3aWJAjGTSKR080PQW3fGA 1 1 0 0 462b 231b
green open .kibana_1 oY_UDLIQT1a5FaqtpBwIoA 1 1 60 7 20.8mb 10.4mb
green open myindex15 EJwz5QEyQqatU34YmfHDtQ 1 1 4 0 48.2kb 24.1kb
green open myindex2 dZZjanvHSgCxlK_0k_ZWIQ 1 2 4 0 59.5kb 19.8kb
green open myindex3 oq87SwCrSySVGiK4pKs2Ug 1 1 6 0 14.5kb 7.2kb
green open myindex4 VleCrjTfQBOVdOU7Lp4MEw 1 1 1 0 13.6kb 6.8kb
green open sspu LSTmGxfsRSK7ZK2CJSEnRA 3 1 0 0 1.2kb 624b
green open myindex5 _EGl89OrTLeTHE7gW4haAw 1 1 4 0 25.2kb 12.6kb
green open .apm-custom-link 1T8drih6SnC3JCnwzykKAw 1 1 0 0 416b 208b
green open .kibana_task_manager_1 sw3RTWrfTkqiknwApCDiQw 1 1 6 62 968.2kb 505.7kb
green open test_index2 wkQWx7CbTuW_O65lS4dj3Q 1 1 1 3 16.6kb 8.3kb
green open xs1 i9cWE3uXQkCjEFuIvnticw 1 1 1 0 11.3kb 5.6kb
green open myindex1 -dECtDmXSe-y2rhAPFzqzA 1 1 11 0 17kb 8.5kb
green open shanghai yZayWlW2Q96v44FjNdv-dg 3 1 0 0 1.2kb 624b
green open test_index CLhMlvA_Qa60QHgjjsjnEg 1 1 1 0 12kb 6kb
green open mydb1 oAAy6ofKS02WnVq2pwyzgw 3 2 1 0 18.6kb 6.2kb
--是否:open,green;
--查看某个索引
curl http://192.168.1.7:9201/_cat/indices/myindex4
green open myindex4 VleCrjTfQBOVdOU7Lp4MEw 1 1 1 0 13.6kb 6.8kb
--文档总数
curl http://192.168.1.7:9201/_cat/count?v
epoch timestamp count
1719647312 07:48:32 124
--recovery的分片的情况
--索引的同步情况。
curl http://192.168.1.7:9201/_cat/recovery
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 16198 100 16198 0 0 255k 0 --:--:-- --:--:-- --:--:-- 259k
xsq1 0 250ms peer done 192.168.1.7 esdb-node-1 192.168.1.7 esdb-node-3 n/a n/a 1 1 100.0% 1 261 261 100.0% 261 0 0 100.0%
xsq1 0 173ms existing_store done n/a n/a 192.168.1.7 esdb-node-1 n/a n/a 0 0 100.0% 1 0 0 100.0% 261 0 0 100.0%
xsq1 1 336ms peer done 192.168.1.7 esdb-node-1 192.168.1.7 esdb-node-2 n/a n/a 1 1 100.0% 1 261 261 100.0% 261 0 0 100.0%
xsq1 1 117ms existing_store done n/a n/a 192.168.1.7 esdb-node-1 n/a n/a 0 0 100.0% 1 0 0 100.0% 261 0 0 100.0%
xsq1 2 153ms existing_store done n/a n/a 192.168.1.7 esdb-node-3 n/a n/a 0 0 100.0% 1 0 0 100.0% 261 0 0 100.0%
xsq1 2 833ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-2 n/a n/a 1 1 100.0% 1 261 261 100.0% 261 0 0 100.0%
xsq1 3 770ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-2 n/a n/a 1 1 100.0% 1 261 261 100.0% 261 0 0 100.0%
xsq1 3 709ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-1 n/a n/a 0 0 0.0% 0 0 0 0.0% 0 0 0 100.0%
xsq1 4 159ms existing_store done n/a n/a 192.168.1.7 esdb-node-3 n/a n/a 0 0 100.0% 7 0 0 100.0% 11383 0 0 100.0%
xsq1 4 862ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-2 n/a n/a 7 7 100.0% 7 11383 11383 100.0% 11383 0 0 100.0%
xsq3 0 664ms peer done 192.168.1.7 esdb-node-1 192.168.1.7 esdb-node-3 n/a n/a 10 10 100.0% 10 12877 12877 100.0% 12877 0 0 100.0%
xsq3 0 167ms existing_store done n/a n/a 192.168.1.7 esdb-node-1 n/a n/a 0 0 100.0% 10 0 0 100.0% 12877 0 0 100.0%
xsq3 1 231ms peer done 192.168.1.7 esdb-node-1 192.168.1.7 esdb-node-2 n/a n/a 4 4 100.0% 4 6781 6781 100.0% 6781 0 0 100.0%
xsq3 1 97ms existing_store done n/a n/a 192.168.1.7 esdb-node-1 n/a n/a 0 0 100.0% 4 0 0 100.0% 6781 0 0 100.0%
xsq3 2 150ms existing_store done n/a n/a 192.168.1.7 esdb-node-3 n/a n/a 0 0 100.0% 18 0 0 100.0% 6918 0 0 100.0%
xsq3 2 924ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-2 n/a n/a 18 18 100.0% 18 6918 6918 100.0% 6918 0 0 100.0%
xsq3 3 298ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-2 n/a n/a 4 4 100.0% 4 6979 6979 100.0% 6979 0 0 100.0%
xsq3 3 133ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-1 n/a n/a 0 0 0.0% 0 0 0 0.0% 0 0 0 100.0%
xsq3 4 147ms existing_store done n/a n/a 192.168.1.7 esdb-node-3 n/a n/a 0 0 100.0% 4 0 0 100.0% 6689 0 0 100.0%
xsq3 4 739ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-2 n/a n/a 4 4 100.0% 4 6689 6689 100.0% 6689 0 0 100.0%
--某个索引同步情况
curl http://192.168.1.7:9201/_cat/recovery/xsq3
xsq3 0 664ms peer done 192.168.1.7 esdb-node-1 192.168.1.7 esdb-node-3 n/a n/a 10 10 100.0% 10 12877 12877 100.0% 12877 0 0 100.0%
xsq3 0 167ms existing_store done n/a n/a 192.168.1.7 esdb-node-1 n/a n/a 0 0 100.0% 10 0 0 100.0% 12877 0 0 100.0%
xsq3 1 231ms peer done 192.168.1.7 esdb-node-1 192.168.1.7 esdb-node-2 n/a n/a 4 4 100.0% 4 6781 6781 100.0% 6781 0 0 100.0%
xsq3 1 97ms existing_store done n/a n/a 192.168.1.7 esdb-node-1 n/a n/a 0 0 100.0% 4 0 0 100.0% 6781 0 0 100.0%
xsq3 2 150ms existing_store done n/a n/a 192.168.1.7 esdb-node-3 n/a n/a 0 0 100.0% 18 0 0 100.0% 6918 0 0 100.0%
xsq3 2 924ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-2 n/a n/a 18 18 100.0% 18 6918 6918 100.0% 6918 0 0 100.0%
xsq3 3 298ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-2 n/a n/a 4 4 100.0% 4 6979 6979 100.0% 6979 0 0 100.0%
xsq3 3 133ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-1 n/a n/a 0 0 0.0% 0 0 0 0.0% 0 0 0 100.0%
xsq3 4 147ms existing_store done n/a n/a 192.168.1.7 esdb-node-3 n/a n/a 0 0 100.0% 4 0 0 100.0% 6689 0 0 100.0%
xsq3 4 739ms peer done 192.168.1.7 esdb-node-3 192.168.1.7 esdb-node-2 n/a n/a 4 4 100.0% 4 6689 6689 100.0% 6689 0 0 100.0%
--集群健康情况 。
curl http://192.168.1.7:9201/_cat/health
1719647418 07:50:18 escluster1 green 3 3 91 42 0 0 0 0 - 100.0%
--查看是否有任务。
curl http://192.168.1.7:9201/_cat/pending_tasks
--别名
curl http://192.168.1.7:9201/_cat/aliases
ilm-history-2 ilm-history-2-000001 - - - true
.kibana-event-log-7.9.2 .kibana-event-log-7.9.2-000001 - - - true
.kibana_task_manager .kibana_task_manager_1 - - - -
.kibana .kibana_1 - - - -
--线程池:
curl http://192.168.1.7:9201/_cat/thread_pool
esdb-node-2 analyze 0 0 0
esdb-node-2 ccr 0 0 0
esdb-node-2 fetch_shard_started 0 0 0
esdb-node-2 fetch_shard_store 0 0 0
esdb-node-2 flush 0 0 0
esdb-node-2 force_merge 0 0 0
esdb-node-2 generic 0 0 0
esdb-node-2 get 0 0 0
esdb-node-2 listener 0 0 0
esdb-node-2 management 1 0 0
esdb-node-2 ml_datafeed 0 0 0
esdb-node-2 ml_job_comms 0 0 0
esdb-node-2 ml_utility 0 0 0
esdb-node-2 refresh 0 0 0
esdb-node-2 rollup_indexing 0 0 0
esdb-node-2 search 0 0 0
esdb-node-2 search_throttled 0 0 0
esdb-node-2 security-crypto 0 0 0
esdb-node-2 security-token-key 0 0 0
esdb-node-2 snapshot 0 0 0
esdb-node-2 transform_indexing 0 0 0
esdb-node-2 warmer 0 0 0
esdb-node-2 watcher 0 0 0
esdb-node-2 write 0 0 0
esdb-node-1 analyze 0 0 0
esdb-node-1 ccr 0 0 0
esdb-node-1 fetch_shard_started 0 0 0
esdb-node-1 fetch_shard_store 0 0 0
esdb-node-1 flush 0 0 0
esdb-node-1 force_merge 0 0 0
esdb-node-1 generic 0 0 0
esdb-node-1 get 0 0 0
esdb-node-1 listener 0 0 0
esdb-node-1 management 1 0 0
esdb-node-1 ml_datafeed 0 0 0
esdb-node-1 ml_job_comms 0 0 0
esdb-node-1 ml_utility 0 0 0
esdb-node-1 refresh 0 0 0
esdb-node-1 rollup_indexing 0 0 0
esdb-node-1 search 0 0 0
esdb-node-1 search_throttled 0 0 0
esdb-node-1 security-crypto 0 0 0
esdb-node-1 security-token-key 0 0 0
esdb-node-1 snapshot 0 0 0
esdb-node-1 transform_indexing 0 0 0
esdb-node-1 warmer 0 0 0
esdb-node-1 watcher 0 0 0
esdb-node-1 write 0 0 0
esdb-node-3 analyze 0 0 0
esdb-node-3 ccr 0 0 0
esdb-node-3 fetch_shard_started 0 0 0
esdb-node-3 fetch_shard_store 0 0 0
esdb-node-3 flush 0 0 0
esdb-node-3 force_merge 0 0 0
esdb-node-3 generic 0 0 0
esdb-node-3 get 0 0 0
esdb-node-3 listener 0 0 0
esdb-node-3 management 1 0 0
esdb-node-3 ml_datafeed 0 0 0
esdb-node-3 ml_job_comms 0 0 0
esdb-node-3 ml_utility 0 0 0
esdb-node-3 refresh 0 0 0
esdb-node-3 rollup_indexing 0 0 0
esdb-node-3 search 0 0 0
esdb-node-3 search_throttled 0 0 0
esdb-node-3 security-crypto 0 0 0
esdb-node-3 security-token-key 0 0 0
esdb-node-3 snapshot 0 0 0
esdb-node-3 transform_indexing 0 0 0
esdb-node-3 warmer 0 0 0
esdb-node-3 watcher 0 0 0
esdb-node-3 write 0 0 0
--列数据
curl http://192.168.1.7:9201/_cat/fielddata
--模板
curl http://192.168.1.7:9201/_cat/templates
.slm-history [.slm-history-2*] 2147483647 2
.monitoring-alerts-7 [.monitoring-alerts-7] 0 7000199
.monitoring-beats [.monitoring-beats-7-*] 0 7000199
.monitoring-kibana [.monitoring-kibana-7-*] 0 7000199
.ml-config [.ml-config] 0 7090299
.transform-notifications-000002 [.transform-notifications-*] 0 7090299
.monitoring-logstash [.monitoring-logstash-7-*] 0 7000199
.transform-internal-005 [.transform-internal-005] 0 7090299
.watches [.watches*] 2147483647 11
.ml-inference-000002 [.ml-inference-000002] 0 7090299
.ml-state [.ml-state*] 0 7090299
.ml-meta [.ml-meta] 0 7090299
.monitoring-es [.monitoring-es-7-*] 0 7000199
template_sspu [sspu*, shanghai*] 0
.logstash-management [.logstash] 0
.kibana-event-log-7.9.2-template [.kibana-event-log-7.9.2-*] 0
.management-beats [.management-beats] 0 70000
.watch-history-11 [.watcher-history-11*] 2147483647 11
.triggered_watches [.triggered_watches*] 2147483647 11
ilm-history [ilm-history-2*] 2147483647 2
.ml-notifications-000001 [.ml-notifications-000001] 0 7090299
xsq [xsq*] 0
.ml-stats [.ml-stats-*] 0 7090299
.ml-anomalies- [.ml-anomalies-*] 0 7090299
logs [logs-*-*] 100 0 [logs-mappings, logs-settings]
metrics [metrics-*-*] 100 0 [metrics-mappings, metrics-settings]
curl http://192.168.1.7:9201/_cat/templates/xsq?v
name index_patterns order version composed_of
xsq [xsq*] 0
--03.查看集群状态
curl -s -XGET 'http://192.168.1.7:9201/_cluster/stats?pretty'
{
"_nodes" : {
"total" : 3,
"successful" : 3,
"failed" : 0
},
"cluster_name" : "escluster1",
"cluster_uuid" : "qcTTcAm9Q9a6gZP0CH_gsA",
"timestamp" : 1719647557109,
"status" : "green",
"indices" : {
"count" : 24,
"shards" : {
"total" : 91,
"primaries" : 42,
"replication" : 1.1666666666666667,
"index" : {
"shards" : {
"min" : 2,
"max" : 10,
"avg" : 3.7916666666666665
},
"primaries" : {
"min" : 1,
"max" : 5,
"avg" : 1.75
},
"replication" : {
"min" : 1.0,
"max" : 2.0,
"avg" : 1.125
}
}
},
"docs" : {
"count" : 140,
"deleted" : 95
},
"store" : {
"size_in_bytes" : 23414920,
"reserved_in_bytes" : 0
},
"fielddata" : {
"memory_size_in_bytes" : 0,
"evictions" : 0
},
"query_cache" : {
"memory_size_in_bytes" : 0,
"total_count" : 0,
"hit_count" : 0,
"miss_count" : 0,
"cache_size" : 0,
"cache_count" : 0,
"evictions" : 0
},
"completion" : {
"size_in_bytes" : 0
},
"segments" : {
"count" : 97,
"memory_in_bytes" : 288060,
"terms_memory_in_bytes" : 197088,
"stored_fields_memory_in_bytes" : 47464,
"term_vectors_memory_in_bytes" : 0,
"norms_memory_in_bytes" : 20672,
"points_memory_in_bytes" : 0,
"doc_values_memory_in_bytes" : 22836,
"index_writer_memory_in_bytes" : 0,
"version_map_memory_in_bytes" : 768,
"fixed_bit_set_memory_in_bytes" : 1440,
"max_unsafe_auto_id_timestamp" : 1719555208877,
"file_sizes" : { }
},
"mappings" : {
"field_types" : [
{
"name" : "binary",
"count" : 9,
"index_count" : 1
},
{
"name" : "boolean",
"count" : 38,
"index_count" : 3
},
{
"name" : "date",
"count" : 68,
"index_count" : 7
},
{
"name" : "flattened",
"count" : 9,
"index_count" : 1
},
{
"name" : "float",
"count" : 3,
"index_count" : 1
},
{
"name" : "integer",
"count" : 29,
"index_count" : 2
},
{
"name" : "keyword",
"count" : 434,
"index_count" : 21
},
{
"name" : "long",
"count" : 36,
"index_count" : 11
},
{
"name" : "nested",
"count" : 13,
"index_count" : 3
},
{
"name" : "object",
"count" : 151,
"index_count" : 8
},
{
"name" : "text",
"count" : 215,
"index_count" : 20
}
]
},
"analysis" : {
"char_filter_types" : [ ],
"tokenizer_types" : [ ],
"filter_types" : [ ],
"analyzer_types" : [ ],
"built_in_char_filters" : [ ],
"built_in_tokenizers" : [ ],
"built_in_filters" : [ ],
"built_in_analyzers" : [ ]
}
},
"nodes" : {
"count" : {
"total" : 3,
"coordinating_only" : 0,
"data" : 3,
"ingest" : 3,
"master" : 3,
"ml" : 3,
"remote_cluster_client" : 0,
"transform" : 3,
"voting_only" : 0
},
"versions" : [
"7.9.2"
],
"os" : {
"available_processors" : 6,
"allocated_processors" : 6,
"names" : [
{
"name" : "Linux",
"count" : 3
}
],
"pretty_names" : [
{
"pretty_name" : "Red Hat Enterprise Linux Server 7.9 (Maipo)",
"count" : 3
}
],
"mem" : {
"total_in_bytes" : 49912479744,
"free_in_bytes" : 17913659392,
"used_in_bytes" : 31998820352,
"free_percent" : 36,
"used_percent" : 64
}
},
"process" : {
"cpu" : {
"percent" : 3
},
"open_file_descriptors" : {
"min" : 379,
"max" : 392,
"avg" : 386
}
},
"jvm" : {
"max_uptime_in_millis" : 1659341,
"versions" : [
{
"version" : "17.0.11",
"vm_name" : "Java HotSpot(TM) 64-Bit Server VM",
"vm_version" : "17.0.11+7-LTS-207",
"vm_vendor" : "Oracle Corporation",
"bundled_jdk" : true,
"using_bundled_jdk" : false,
"count" : 3
}
],
"mem" : {
"heap_used_in_bytes" : 463607480,
"heap_max_in_bytes" : 805306368
},
"threads" : 172
},
"fs" : {
"total_in_bytes" : 53660876800,
"free_in_bytes" : 30232244224,
"available_in_bytes" : 30232244224
},
"plugins" : [ ],
"network_types" : {
"transport_types" : {
"security4" : 3
},
"http_types" : {
"security4" : 3
}
},
"discovery_types" : {
"zen" : 3
},
"packaging_types" : [
{
"flavor" : "default",
"type" : "tar",
"count" : 3
}
],
"ingest" : {
"number_of_pipelines" : 2,
"processor_stats" : {
"gsub" : {
"count" : 0,
"failed" : 0,
"current" : 0,
"time_in_millis" : 0
},
"script" : {
"count" : 0,
"failed" : 0,
"current" : 0,
"time_in_millis" : 0
}
}
}
}
}
--04.查询状态为red的索引
--查看不健康的索引。
curl -s -XGET 'http://192.168.1.7:9201/_cat/indices?health=red'