kdb_ps

Langue: en

Version: 252919 (debian - 07/07/09)

Section: 1 (Commandes utilisateur)

NAME

ps - Display processes

SYNOPSIS

ps [ DRSTCZEUIMA ]

DESCRIPTION

The ps command displays the status of all processes in the desired state. This command does not take any locks (all cpus should be frozen while kdb is running) so it can safely be used to debug lock problems with the process table.

Without any parameters, ps displays all the interesting processes, excluding idle tasks and sleeping system daemons. If a parameter is specified, it is a single string consisting of the letters D, R, S, T, C, Z, E, U, I and M, in any order. Each letter selects processes in a specific state, when multiple letters are specified, a process will be displayed if it is in any of the specified states. The states are :-

D Uninterruptible sleep
R Running
S Interruptible sleep
T Stopped
C Traced
Z Zombie
E Dead
U Unrunnable
I Idle task
M Sleeping system daemon
A All

For state R (running), the process may not be on a cpu at the moment, but it is ready to run. The header line above the backtrace contains '1' in the fourth field if the process is actually on a cpu.

The idle task is run on each cpu when there is no work for that cpu to do. Unless the idle task is servicing an interrupt, there is no point in printing the idle task. An idle task that is not servicing a interrupt is marked as state I, while servicing an interrupt it is in state R. By default, idle tasks are not printed, use ps I to print them. If the idle tasks are not being printed, the start of the psR output contains a list of which cpus are idle.

Each cpu has one or more system daemons to handle per cpu work such as soft irqs. A system daemon (idenified by a NULL mm pointer) that is sleeping is marked as state M. These processes rarely have any useful data and generate a lot of output on large machines, so sleeping system daemons are not printed by default. Use ps M to print them.

At the start of the ps output is a line giving the cpu status, see the kdb cpu command.

LIMITATIONS

None.

ENVIRONMENT

PS
This environment variable (default=DRSTCZEU) is used when ps is issued with no parameters.

SMP CONSIDERATIONS

None.

EXAMPLES

ps
displays the useful tasks, suppressing idle tasks and sleeping system daemons.
ps RD
displays only tasks that are running or are in an uninterruptible sleep.
ps DRSTCZEUIM
displays all tasks.
ps A
displays all tasks. This is easier than remembering DRSTCZEUIM.