onstat -g wai 命令:打印等待队列线程队列

可以使用 onstat -g wai 命令显示当前在等待队列中并没有得到执行的系统上的线程列表。输出按线程 ID 排序。

语法:

示例输出

图: onstat -g wai 命令输出

            Waiting threads:
            tid     tcb             rstcb            prty status                vp-      name
            2       46b1ea40         0                1    IO Idle                 5lio        lio vp 0
            3       46b3dc58         0                1    IO Idle                 6pio        pio vp 0
            4       46b5dc58         0                1    IO Idle                 7aio        aio vp 0
            5       46b7cc58         0                1    IO Idle                 8msc        msc vp 0
            6       46b1ed10         460f5028         1    sleeping secs: 1        3cpu        main_loop()
            9       46d0d6e0         0                1    sleeping forever        1cpu        soctcplst
            10      46d70b48         0                1    sleeping forever        3cpu        sm_listen
            11      46e5d9a0         0                1    sleeping secs: 1        3cpu        sm_discon
            12      46e5dc70         460f5820         1    sleeping secs: 1        3cpu        flush_sub(0)
            13      46e8a5a8         460f6018         1    sleeping secs: 1        3cpu        aslogflush
            14      46fe8148         460f6810         1    sleeping secs: 41       3cpu        btscanner_0
            15      46fe84a8         0                1    IO Idle                10aio        aio vp 1
            16      46fe8778         460f7008         1    sleeping secs: 1        1cpu        onmode_mon
            36      47531960         460f7ff8         1    sleeping secs: 253      3cpu        dbScheduler
            37      47531c30         460f87f0         1    sleeping forever        4cpu        dbWorker1
            38      47491028         460f7800         1    sleeping forever        4cpu        dbWorker2
          

输出描述

tid (decimal)
线程 ID
tcb (hex)
线程控制 block 的内存地址
rstcb (hex)
RSAM 线程控制 block 的内存地址
prty (decimal)
线程优先级。较大的数字代表较高的优先级
status (string)
线程的当前状态
vp- (decimal and string)
上次运行线程的 VP 的虚拟处理器整数 ID 与运行线程的 VP 类的名称连接
name (string)
线程名称