ElasticSearch之cat task management API

发布时间 2023-11-29 00:34:32作者: jackieathome

命令样例如下:

curl -X GET "https://localhost:9200/_cat/tasks?v=true&pretty" --cacert $ES_HOME/config/certs/http_ca.crt -u "elastic:ohCxPH=QBE+s5=*lo7F9"

执行结果输出如下:

action                         task_id                      parent_task_id               type       start_time    timestamp running_time ip        node
health-node[c]                 aKgBu7LgS9a6iPYH8n2JPw:32    cluster:5                    persistent 1700843700401 16:35:00  3.9d         127.0.0.1 jackie-ubuntu
geoip-downloader[c]            aKgBu7LgS9a6iPYH8n2JPw:33    cluster:6                    persistent 1700843700402 16:35:00  3.9d         127.0.0.1 jackie-ubuntu
cluster:monitor/tasks/lists    aKgBu7LgS9a6iPYH8n2JPw:69227 -                            transport  1701189085355 16:31:25  5.6s         127.0.0.1 jackie-ubuntu
cluster:monitor/tasks/lists[n] aKgBu7LgS9a6iPYH8n2JPw:69228 aKgBu7LgS9a6iPYH8n2JPw:69227 direct     1701189087462 16:31:27  3.5s         127.0.0.1 jackie-ubuntu

查看帮助,命令如下:

curl -X GET "https://localhost:9200/_cat/tasks?v=true&help=true&pretty" --cacert $ES_HOME/config/certs/http_ca.crt -u "elastic:ohCxPH=QBE+s5=*lo7F9"

执行结果输出如下:

id              |               | id of the task with the node
action          | ac            | task action
task_id         | ti            | unique task id
parent_task_id  | pti           | parent task id
type            | ty            | task type
start_time      | start         | start time in ms
timestamp       | ts,hms,hhmmss | start time in HH:MM:SS
running_time_ns | time          | running time ns
running_time    | time          | running time
node_id         | ni            | unique node id
ip              | i             | ip address
port            | po            | bound transport port
node            | n             | node name
version         | v             | es version
x_opaque_id     | x             | X-Opaque-ID header

相关资料