Batch

目录

介绍

通过 orxray batch 子命令可以获取批量任务列表和指定批次的所有任务信息。

回到目录

用法

Usage: orxray batch [COMMAND]

COMMAND:
    list
    show

GLOBAL OPTIONS:
    --help
    --config                           Specify the config file, default is ~/.orxray/config.

回到目录

List

这个子命令可以打印出批量任务的列表。

回到目录

用法

Usage: orxray batch list [OPTIONS]

OPTIONS:
    -a, --agent                        Agent ID, or use default agent.
    -s, --page-size                    page size, 20(default).
    -p, --page                             page, 1(default).

GLOBAL OPTIONS:
    --help
    --config                           Specify the config file, default is ~/.orxray/config.

回到目录

示例

$ orxray batch list
ID      RESOURCES       APP_ID  PID     PGID    USER
11      cpu             267                     test@openresty.com
10      cpu,disk        267             3210677 test@openresty.com
9       cpu             267                     test@openresty.com

指定列表的最大显示数量

$ orxray batch list -s 2
ID      RESOURCES       APP_ID  PID     PGID    USER
11      cpu             267                     test@openresty.com
10      cpu,disk        267             3210677 test@openresty.com

回到目录

Show

获取指定批次的所有任务信息。

用法

Usage: orxray batch show [BATCH_ID] [OPTIONS]

OPTIONS:
    -a, --agent                        Agent ID, or use default agent.
    -s, --page-size                    page size, 20(default).
    -p, --page                         page, 1(default).

GLOBAL OPTIONS:
    --help
    --config                           Specify the config file, default is ~/.orxray/config.

回到目录

示例

$ orxray batch show 10
ID      ANALYZER                RUNNING TIME(sec)       USER    STATUS          MSG
4061182 vfs-read-write-fgraph   6.87                    system  finished        Got 0 samples
4061174 vfs-write-top-files     18.88                   system  finished        Got 0 samples
4061168 vfs-read-top-files      18.99                   system  finished        Got 0 samples
4061159 lj-lua-off-cpu          31.06                   system  finished        Got 0 samples
4061153 lj-lua-on-cpu           16.11                   system  finished        Got 0 samples
4061148 lj-c-off-cpu            17.19                   system  finished
4061141 lj-c-on-cpu             17.12                   system  finished

回到目录

Show Report

展示批量运行完成后生成的报告内容。

用法

Usage: orxray batch show-report [BATCH_ID]

GLOBAL OPTIONS:
    --help
    --config                           Specify the config file, default is ~/.orxray/config.

回到目录

示例

$ orxray batch show-report 307
We, the [OpenResty Inc.](https://openresty.com/) expert team, have analyzed the
customer data collected by the [OpenResty XRay](https://openresty.com/en/xray/) system
for about **1.05 min** (2024-01-30 8am UTC ~ 2024-01-30 8am UTC) across **0** customer
servers. We then prepared this analysis report to provide a detailed analysis and actionable suggestions for the customer's applications.

...

回到目录