x_cons <database_name> show sleep
Shows statistics that indicate how long the individual user kernel threads were idle. The values can be seen if the time measurement is enabled.
- Task Group: UKT Id that the task belongs to.
- Idle Time Intervals: Number of Idle times of the current task inside the dispatcher
- I/O Wait Intervals: Number of waits for I/O completion
- I/O Time dd:hh:mm:ss : Wait duration
- RunQueue Length: Length of the run queue in the dispatcher
- CSwitch Intervals: Number of context switches
- CSwitch hh:mm:ss:mmm : Duration of context switches, this value can be seen if the time measurement is enabled.
- Scheduling Intervals: Number of scheduling inside the dispatcher including the time to scan the queues ( run queue, external queue, com queue)
- Scheduling hh:mm:ss:mmm: Duration spent in scheduling inside the dispatcher.
Particular attention should be paid to the columns, "Idle Time Intervals" and "RunQueue Length". The growth of the numbers in "RunQueue Length" indicates that within a UKT database tasks are waiting for CPU allocation, but another task within the same UKT holds the CPU. These waiting tasks can be displayed with "x_cons show runnable" command. If "Idle Time Intervals" does not change then the UKT is always working, it indicates a long running database procedure which does not give control back to the database kernel and cannot be dispatched. This can cause performance problems, since all other tasks that run in the same UKT cannot work. Time measurement has to be enabled to see the values for "CSwitch" and "CSwitch hh:mm:ss:mmm".