]> git.lizzy.rs Git - plan9front.git/blob - sys/man/1/ps
merge
[plan9front.git] / sys / man / 1 / ps
1 .TH PS 1
2 .SH NAME
3 ps, psu, pstree \- process status
4 .SH SYNOPSIS
5 .B ps
6 [
7 .B -apnr
8 ]
9 .PP
10 .B psu
11 [
12 .B -apnr
13 ]
14 [
15 .I user
16 ]
17 .PP
18 .B pstree
19 .SH DESCRIPTION
20 .I Ps
21 prints information about processes.
22 .I Psu
23 prints only information about processes started by
24 .I user
25 (default
26 .BR $user ).
27 .PP
28 For each process reported,
29 the user,
30 process id,
31 user time,
32 system time,
33 size,
34 state,
35 and command name are printed.
36 State is one of the following:
37 .TP \w'\fLno\ \fIresource\ \ \ 'u
38 .B Moribund
39 Process has exited and is about to have its
40 resources reclaimed.
41 .TP
42 .B Ready
43 on the queue of processes ready to be run.
44 .TP
45 .B Scheding
46 about to be run.
47 .TP
48 .B Running
49 running.
50 .TP
51 .B Queueing
52 waiting on a queue for a resource.
53 .TP
54 .B Wakeme
55 waiting for I/O or some other kernel event to wake it up.
56 .TP
57 .B Broken
58 dead of unnatural causes; lingering
59 so that it can be examined.
60 .TP
61 .B Stopped
62 stopped.
63 .TP
64 .B Stopwait
65 waiting for another process to stop.
66 .TP
67 .B Fault
68 servicing a page fault.
69 .TP
70 .B Idle
71 waiting for something to do (kernel processes only).
72 .TP
73 .B New
74 being created.
75 .TP
76 .B Pageout
77 paging out some other process.
78 .TP
79 .I Syscall
80 performing the named system call.
81 .TP
82 .BI no " resource
83 waiting for more of a critical
84 .IR resource .
85 .PD
86 .PP
87 The
88 .B -n
89 flag causes
90 .I ps
91 to print, after the process id, the note group to which the process belongs.
92 .PP
93 The
94 .B -r
95 flag causes
96 .I ps
97 to print, before the user time, the elapsed real time for the process.
98 .PP
99 The
100 .B -p
101 flag causes
102 .I ps
103 to print, after the system time, the baseline and current priorities of each process.
104 .PP
105 The
106 .B -a
107 flag causes
108 .I ps
109 to print the arguments for the process.  Newlines in arguments will be translated to spaces for display.
110 .PP
111 .I Pstree
112 prints the processes as a tree in a two colum layout where
113 the first colum being the process id and second column
114 the program name and arguments indented and prefixed with
115 line drawing runes to reflect the nesting in the hierarchy.
116 .SH FILES
117 .B /proc/*/status
118 .SH SOURCE
119 .B /sys/src/cmd/ps.c
120 .br
121 .B /rc/bin/psu
122 .br
123 .B /sys/src/cmd/pstree.c
124 .SH "SEE ALSO"
125 .IR acid (1),
126 .IR db (1),
127 .IR kill (1), 
128 .IR ns (1),
129 .IR proc (3)
130 .SH HISTORY
131 .I Pstree
132 first appeared in 9front (June, 2011).