1PCP-PS(1) General Commands Manual PCP-PS(1)
2
3
4
6 pcp-ps - Report statistics for Linux Process.
7
9 pcp [pcp options] ps [-e] [-U [username]] [-V --version] [-c Command
10 name] [-p pid1,pid2..] [-p pid1,pid2..] [-o col1,col2... or ALL] [-Z
11 timezone] [-z] [-?]
12
14 The pcp-ps command is used for monitoring individual process running on
15 the system. Using various options it helps a user to see useful infor‐
16 mation related to the processes. This information includes CPU per‐
17 centage, memory and stack usage, scheduling and priority. By default
18 pcp-ps reports live data for the local host.
19
21 When invoked via the pcp(1) command, the -h/--host, -O/--origin,
22 -t/--interval, -Z/--timezone and several other pcp options become indi‐
23 rectly available; refer to PCPIntro(1) for a complete description of
24 these options.
25
26 The additional command line options available for pcp-ps are:
27
28 -e Display all the process.
29
30 PID
31 Process idenfier.
32
33 TTY
34 The termianl assoicated with the prcoess.
35
36 TIME
37 The cumulated CPU time in [DD-]hh:mm:ss format
38 (time=TIME).
39
40 CMD
41 The command name of the task.
42
43 -c [command name]
44 Display the real Command name of the tasks being monitored instead
45 of the UID. If command name is specified, then only tasks belong‐
46 ing to the specified command are displayed.
47
48 -U [username], --user-name[=username]
49 Display the real user name of the tasks being monitored instead of
50 the UID. If username is specified, then only tasks belonging to
51 the specified user are displayed.
52
53 -V, --version
54 Print version number then exit.
55
56 -p pid1,pid2.., --pid-list=pid1,pid2..
57 Display only processes with the listed PIDs.
58
59 -P ppid1,ppid2.., --ppid-list=ppid1,ppid2..
60 Display only processes with the listed PPIDs.
61
62 -O User-defined format.
63
64 It is a single argument in the form of a blank-separated or comma-
65 separated list, which offers a way to specify individual output
66 columns.
67
68 The argument to -o are following:
69
70
71 COL HEADER DESCRIPTION
72
73 %cpu %CPU cpu utilization of the process
74
75 %mem %MEM physical memory on the machine expressed as a percentage
76
77 start START time the command started
78
79 time TIME accumulated cpu time, user + system
80
81 cls CLS scheduling class of the process
82
83 cmd CMD see args. (alias args, command).
84
85 pid PID The process ID
86
87 ppid PPID Parent process ID
88
89 pri PRI Priority of the process
90
91 state S see s
92
93 rss RSS the non-swapped physical memory that a task has used
94
95 rtprio RTPRIO realtime priority
96
97 pname Pname Process name
98
99 tty TT controlling tty (terminal)
100
101 uid UID see euid
102
103 vsize VSZ see vsz
104
105 uname USER see euser
106
107 wchan WCHAN name of the kernel function in which the process is sleeping
108
109
111 Here are the different keywords that may be used to control the output
112 format (e.g. with option -o) or to sort the selected processes
113
114 For example: ps -o pid,user,args
115
116
117 CODE HEADER DESCRIPTION
118 pid PID a number representing the process ID
119 %cpu %CPU cpu utilization of the process in "##.#" format.
120 Currently, it is the CPU time used divided by the time the
121 process has been running (cputime/realtime ratio), expressed as a percentage.
122 %mem %MEM ratio of the process's resident set size to the physical memory on the
123 machine, expressed as a percentage.
124 args COMMAND Command with all its arguments as a string. Modifications to the arguments
125 may be shown. The output in this column may contain spaces. A process
126 marked <defunct> is partly dead, waiting to be fully destroyed by its parent.
127 Sometimes the process args will be unavailable; when this happens,will instead print the executable name in brackets.
128 class CLS scheduling class of the process.
129
130 Field's possible values are:
131 - not reported
132
133 TS SCHED_OTHER
134 FF SCHED_FIFO
135 RR SCHED_RR
136 B SCHED_BATCH
137 ISO SCHED_ISO
138 IDL SCHED_IDLE
139 DLN SCHED_DEADLINE
140 ? unknown value
141
142
143 s S minimal state display.See also stat if you want additional information displayed.
144 euid EUID effective user ID.
145 vsz VSZ virtual memory size of the process in KiB (1024-byte units).Device mappings are currently excluded; this is subject to change.
146 euser EUSER effective user name. This will be the textual user ID, if it can be obtained and the field width permits, or a decimal representation otherwise.
147
148 All
149 ALL option shows
150 USER,PID,PPID,PRI,%CPU,%MEM,VSZ,RSS,S,STARTED,TIME,WCHAN and Command by
151 default
152
153 -Z timezone, --timezone=timezone
154 By default, pcp-ps reports the time of day according to the lo‐
155 cal timezone on the system where pcp-ps is run. The -Z option
156 changes the timezone to timezone in the format of the environ‐
157 ment variable TZ as described in environ(7).
158
159 -z , --hostzone
160 Change the reporting timezone to the local timezone at the host
161 that is the source of the performance metrics. When replaying a
162 PCP archive that was captured in a foreign timezone, the -z op‐
163 tion would almost always be used (the default reporting timezone
164 is the local timezone, which may not be the same as the timezone
165 of the PCP archive).
166
167 -? , --help
168 Display usage message and exit.
169
171 pcp-ps is inspired by the ps(1) command and aims to be command line and
172 output compatible with it.
173
175 Environment variables with the prefix PCP_ are used to parameterize the
176 file and directory names used by PCP. On each installation, the file
177 /etc/pcp.conf contains the local values for these variables. The
178 $PCP_CONF variable may be used to specify an alternative configuration
179 file, as described in pcp.conf(5).
180
181 For environment variables affecting PCP tools, see pmGetOptions(3).
182
184 PCPIntro(1), pcp(1), pcp-ps(1), python(1), pmParseInterval(3), strf‐
185 time(3) and environ(7).
186
187
188
189Performance Co-Pilot PCP PCP-PS(1)