1PS(1) User Commands PS(1)
2
3
4
6 ps - report a snapshot of the current processes.
7
9 ps [options]
10
12 ps displays information about a selection of the active processes. If
13 you want a repetitive update of the selection and the displayed
14 information, use top(1) instead.
15
16 This version of ps accepts several kinds of options:
17
18 1 UNIX options, which may be grouped and must be preceded by a dash.
19 2 BSD options, which may be grouped and must not be used with a dash.
20 3 GNU long options, which are preceded by two dashes.
21
22 Options of different types may be freely mixed, but conflicts can
23 appear. There are some synonymous options, which are functionally
24 identical, due to the many standards and ps implementations that this
25 ps is compatible with.
26
27 Note that "ps -aux" is distinct from "ps aux". The POSIX and UNIX
28 standards require that "ps -aux" print all processes owned by a user
29 named "x", as well as printing all processes that would be selected by
30 the -a option. If the user named "x" does not exist, this ps may
31 interpret the command as "ps aux" instead and print a warning. This
32 behavior is intended to aid in transitioning old scripts and habits.
33 It is fragile, subject to change, and thus should not be relied upon.
34
35 By default, ps selects all processes with the same effective user ID
36 (euid=EUID) as the current user and associated with the same terminal
37 as the invoker. It displays the process ID (pid=PID), the terminal
38 associated with the process (tname=TTY), the cumulated CPU time in
39 [DD-]hh:mm:ss format (time=TIME), and the executable name (ucmd=CMD).
40 Output is unsorted by default.
41
42 The use of BSD-style options will add process state (stat=STAT) to the
43 default display and show the command args (args=COMMAND) instead of the
44 executable name. You can override this with the PS_FORMAT environment
45 variable. The use of BSD-style options will also change the process
46 selection to include processes on other terminals (TTYs) that are owned
47 by you; alternately, this may be described as setting the selection to
48 be the set of all processes filtered to exclude processes owned by
49 other users or not on a terminal. These effects are not considered
50 when options are described as being "identical" below, so -M will be
51 considered identical to Z and so on.
52
53 Except as described below, process selection options are additive. The
54 default selection is discarded, and then the selected processes are
55 added to the set of processes to be displayed. A process will thus be
56 shown if it meets any of the given selection criteria.
57
59 To see every process on the system using standard syntax:
60 ps -e
61 ps -ef
62 ps -eF
63 ps -ely
64
65 To see every process on the system using BSD syntax:
66 ps ax
67 ps axu
68
69 To print a process tree:
70 ps -ejH
71 ps axjf
72
73 To get info about threads:
74 ps -eLf
75 ps axms
76
77 To get security info:
78 ps -eo euser,ruser,suser,fuser,f,comm,label
79 ps axZ
80 ps -eM
81
82 To see every process running as root (real & effective ID) in user
83 format:
84 ps -U root -u root u
85
86 To see every process with a user-defined format:
87 ps -eo pid,tid,class,rtprio,ni,pri,psr,pcpu,stat,wchan:14,comm
88 ps axo stat,euid,ruid,tty,tpgid,sess,pgrp,ppid,pid,pcpu,comm
89 ps -Ao pid,tt,user,fname,tmout,f,wchan
90
91 Print only the process IDs of syslogd:
92 ps -C syslogd -o pid=
93
94 Print only the name of PID 42:
95 ps -q 42 -o comm=
96
98 a Lift the BSD-style "only yourself" restriction, which is imposed
99 upon the set of all processes when some BSD-style (without "-")
100 options are used or when the ps personality setting is BSD-like.
101 The set of processes selected in this manner is in addition to
102 the set of processes selected by other means. An alternate
103 description is that this option causes ps to list all processes
104 with a terminal (tty), or to list all processes when used
105 together with the x option.
106
107 -A Select all processes. Identical to -e.
108
109 -a Select all processes except both session leaders (see getsid(2))
110 and processes not associated with a terminal.
111
112 -d Select all processes except session leaders.
113
114 --deselect
115 Select all processes except those that fulfill the specified
116 conditions (negates the selection). Identical to -N.
117
118 -e Select all processes. Identical to -A.
119
120 g Really all, even session leaders. This flag is obsolete and may
121 be discontinued in a future release. It is normally implied by
122 the a flag, and is only useful when operating in the sunos4
123 personality.
124
125 -N Select all processes except those that fulfill the specified
126 conditions (negates the selection). Identical to --deselect.
127
128 T Select all processes associated with this terminal. Identical
129 to the t option without any argument.
130
131 r Restrict the selection to only running processes.
132
133 x Lift the BSD-style "must have a tty" restriction, which is
134 imposed upon the set of all processes when some BSD-style
135 (without "-") options are used or when the ps personality
136 setting is BSD-like. The set of processes selected in this
137 manner is in addition to the set of processes selected by other
138 means. An alternate description is that this option causes ps
139 to list all processes owned by you (same EUID as ps), or to list
140 all processes when used together with the a option.
141
143 These options accept a single argument in the form of a blank-separated
144 or comma-separated list. They can be used multiple times. For
145 example: ps -p "1 2" -p 3,4
146
147 -123 Identical to --pid 123.
148
149 123 Identical to --pid 123.
150
151 -C cmdlist
152 Select by command name. This selects the processes whose
153 executable name is given in cmdlist.
154
155 -G grplist
156 Select by real group ID (RGID) or name. This selects the
157 processes whose real group name or ID is in the grplist list.
158 The real group ID identifies the group of the user who created
159 the process, see getgid(2).
160
161 -g grplist
162 Select by session OR by effective group name. Selection by
163 session is specified by many standards, but selection by
164 effective group is the logical behavior that several other
165 operating systems use. This ps will select by session when the
166 list is completely numeric (as sessions are). Group ID numbers
167 will work only when some group names are also specified. See
168 the -s and --group options.
169
170 --Group grplist
171 Select by real group ID (RGID) or name. Identical to -G.
172
173 --group grplist
174 Select by effective group ID (EGID) or name. This selects the
175 processes whose effective group name or ID is in grplist. The
176 effective group ID describes the group whose file access
177 permissions are used by the process (see getegid(2)). The -g
178 option is often an alternative to --group.
179
180 p pidlist
181 Select by process ID. Identical to -p and --pid.
182
183 -p pidlist
184 Select by PID. This selects the processes whose process ID
185 numbers appear in pidlist. Identical to p and --pid.
186
187 --pid pidlist
188 Select by process ID. Identical to -p and p.
189
190 --ppid pidlist
191 Select by parent process ID. This selects the processes with a
192 parent process ID in pidlist. That is, it selects processes
193 that are children of those listed in pidlist.
194
195 q pidlist
196 Select by process ID (quick mode). Identical to -q and
197 --quick-pid.
198
199 -q pidlist
200 Select by PID (quick mode). This selects the processes whose
201 process ID numbers appear in pidlist. With this option ps reads
202 the necessary info only for the pids listed in the pidlist and
203 doesn't apply additional filtering rules. The order of pids is
204 unsorted and preserved. No additional selection options, sorting
205 and forest type listings are allowed in this mode. Identical to
206 q and --quick-pid.
207
208 --quick-pid pidlist
209 Select by process ID (quick mode). Identical to -q and q.
210
211 -s sesslist
212 Select by session ID. This selects the processes with a session
213 ID specified in sesslist.
214
215 --sid sesslist
216 Select by session ID. Identical to -s.
217
218 t ttylist
219 Select by tty. Nearly identical to -t and --tty, but can also
220 be used with an empty ttylist to indicate the terminal
221 associated with ps. Using the T option is considered cleaner
222 than using t with an empty ttylist.
223
224 -t ttylist
225 Select by tty. This selects the processes associated with the
226 terminals given in ttylist. Terminals (ttys, or screens for
227 text output) can be specified in several forms: /dev/ttyS1,
228 ttyS1, S1. A plain "-" may be used to select processes not
229 attached to any terminal.
230
231 --tty ttylist
232 Select by terminal. Identical to -t and t.
233
234 U userlist
235 Select by effective user ID (EUID) or name. This selects the
236 processes whose effective user name or ID is in userlist. The
237 effective user ID describes the user whose file access
238 permissions are used by the process (see geteuid(2)). Identical
239 to -u and --user.
240
241 -U userlist
242 Select by real user ID (RUID) or name. It selects the processes
243 whose real user name or ID is in the userlist list. The real
244 user ID identifies the user who created the process, see
245 getuid(2).
246
247 -u userlist
248 Select by effective user ID (EUID) or name. This selects the
249 processes whose effective user name or ID is in userlist.
250
251 The effective user ID describes the user whose file access
252 permissions are used by the process (see geteuid(2)). Identical
253 to U and --user.
254
255 --User userlist
256 Select by real user ID (RUID) or name. Identical to -U.
257
258 --user userlist
259 Select by effective user ID (EUID) or name. Identical to -u and
260 U.
261
263 These options are used to choose the information displayed by ps. The
264 output may differ by personality.
265
266 -c Show different scheduler information for the -l option.
267
268 --context
269 Display security context format (for SELinux).
270
271 -f Do full-format listing. This option can be combined with many
272 other UNIX-style options to add additional columns. It also
273 causes the command arguments to be printed. When used with -L,
274 the NLWP (number of threads) and LWP (thread ID) columns will be
275 added. See the c option, the format keyword args, and the
276 format keyword comm.
277
278 -F Extra full format. See the -f option, which -F implies.
279
280 --format format
281 user-defined format. Identical to -o and o.
282
283 j BSD job control format.
284
285 -j Jobs format.
286
287 l Display BSD long format.
288
289 -l Long format. The -y option is often useful with this.
290
291 -M Add a column of security data. Identical to Z (for SELinux).
292
293 O format
294 is preloaded o (overloaded). The BSD O option can act like -O
295 (user-defined output format with some common fields predefined)
296 or can be used to specify sort order. Heuristics are used to
297 determine the behavior of this option. To ensure that the
298 desired behavior is obtained (sorting or formatting), specify
299 the option in some other way (e.g. with -O or --sort). When
300 used as a formatting option, it is identical to -O, with the BSD
301 personality.
302
303 -O format
304 Like -o, but preloaded with some default columns. Identical to
305 -o pid,format,state,tname,time,command or -o pid,format,tname,
306 time,cmd, see -o below.
307
308 o format
309 Specify user-defined format. Identical to -o and --format.
310
311 -o format
312 User-defined format. format is a single argument in the form of
313 a blank-separated or comma-separated list, which offers a way to
314 specify individual output columns. The recognized keywords are
315 described in the STANDARD FORMAT SPECIFIERS section below.
316 Headers may be renamed (ps -o pid,ruser=RealUser -o
317 comm=Command) as desired. If all column headers are empty (ps
318 -o pid= -o comm=) then the header line will not be output.
319 Column width will increase as needed for wide headers; this may
320 be used to widen up columns such as WCHAN (ps -o pid,wchan=WIDE-
321 WCHAN-COLUMN -o comm). Explicit width control (ps opid,
322 wchan:42,cmd) is offered too. The behavior of ps -o pid=X,
323 comm=Y varies with personality; output may be one column named
324 "X,comm=Y" or two columns named "X" and "Y". Use multiple -o
325 options when in doubt. Use the PS_FORMAT environment variable
326 to specify a default as desired; DefSysV and DefBSD are macros
327 that may be used to choose the default UNIX or BSD columns.
328
329 s Display signal format.
330
331 u Display user-oriented format.
332
333 v Display virtual memory format.
334
335 X Register format.
336
337 -y Do not show flags; show rss in place of addr. This option can
338 only be used with -l.
339
340 Z Add a column of security data. Identical to -M (for SELinux).
341
343 c Show the true command name. This is derived from the name of
344 the executable file, rather than from the argv value. Command
345 arguments and any modifications to them are thus not shown.
346 This option effectively turns the args format keyword into the
347 comm format keyword; it is useful with the -f format option and
348 with the various BSD-style format options, which all normally
349 display the command arguments. See the -f option, the format
350 keyword args, and the format keyword comm.
351
352 --cols n
353 Set screen width.
354
355 --columns n
356 Set screen width.
357
358 --cumulative
359 Include some dead child process data (as a sum with the parent).
360
361 e Show the environment after the command.
362
363 f ASCII art process hierarchy (forest).
364
365 --forest
366 ASCII art process tree.
367
368 h No header. (or, one header per screen in the BSD personality).
369 The h option is problematic. Standard BSD ps uses this option
370 to print a header on each page of output, but older Linux ps
371 uses this option to totally disable the header. This version of
372 ps follows the Linux usage of not printing the header unless the
373 BSD personality has been selected, in which case it prints a
374 header on each page of output. Regardless of the current
375 personality, you can use the long options --headers and
376 --no-headers to enable printing headers each page or disable
377 headers entirely, respectively.
378
379 -H Show process hierarchy (forest).
380
381 --headers
382 Repeat header lines, one per page of output.
383
384 k spec Specify sorting order. Sorting syntax is
385 [+|-]key[,[+|-]key[,...]]. Choose a multi-letter key from the
386 STANDARD FORMAT SPECIFIERS section. The "+" is optional since
387 default direction is increasing numerical or lexicographic
388 order. Identical to --sort.
389
390 Examples:
391 ps jaxkuid,-ppid,+pid
392 ps axk comm o comm,args
393 ps kstart_time -ef
394
395 --lines n
396 Set screen height.
397
398 n Numeric output for WCHAN and USER (including all types of UID
399 and GID).
400
401 --no-headers
402 Print no header line at all. --no-heading is an alias for this
403 option.
404
405 O order
406 Sorting order (overloaded). The BSD O option can act like -O
407 (user-defined output format with some common fields predefined)
408 or can be used to specify sort order. Heuristics are used to
409 determine the behavior of this option. To ensure that the
410 desired behavior is obtained (sorting or formatting), specify
411 the option in some other way (e.g. with -O or --sort).
412
413 For sorting, obsolete BSD O option syntax is
414 O[+|-]k1[,[+|-]k2[,...]]. It orders the processes listing
415 according to the multilevel sort specified by the sequence of
416 one-letter short keys k1,k2, ... described in the OBSOLETE SORT
417 KEYS section below. The "+" is currently optional, merely
418 re-iterating the default direction on a key, but may help to
419 distinguish an O sort from an O format. The "-" reverses
420 direction only on the key it precedes.
421
422 --rows n
423 Set screen height.
424
425 S Sum up some information, such as CPU usage, from dead child
426 processes into their parent. This is useful for examining a
427 system where a parent process repeatedly forks off short-lived
428 children to do work.
429
430 --sort spec
431 Specify sorting order. Sorting syntax is
432 [+|-]key[,[+|-]key[,...]]. Choose a multi-letter key from the
433 STANDARD FORMAT SPECIFIERS section. The "+" is optional since
434 default direction is increasing numerical or lexicographic
435 order. Identical to k. For example: ps jax --sort=uid,-ppid,
436 +pid
437
438 w Wide output. Use this option twice for unlimited width.
439
440 -w Wide output. Use this option twice for unlimited width.
441
442 --width n
443 Set screen width.
444
446 H Show threads as if they were processes.
447
448 -L Show threads, possibly with LWP and NLWP columns.
449
450 m Show threads after processes.
451
452 -m Show threads after processes.
453
454 -T Show threads, possibly with SPID column.
455
457 --help section
458 Print a help message. The section argument can be one of
459 simple, list, output, threads, misc or all. The argument can be
460 shortened to one of the underlined letters as in: s|l|o|t|m|a.
461
462 --info Print debugging info.
463
464 L List all format specifiers.
465
466 V Print the procps-ng version.
467
468 -V Print the procps-ng version.
469
470 --version
471 Print the procps-ng version.
472
474 This ps works by reading the virtual files in /proc. This ps does not
475 need to be setuid kmem or have any privileges to run. Do not give this
476 ps any special permissions.
477
478 CPU usage is currently expressed as the percentage of time spent
479 running during the entire lifetime of a process. This is not ideal,
480 and it does not conform to the standards that ps otherwise conforms to.
481 CPU usage is unlikely to add up to exactly 100%.
482
483 The SIZE and RSS fields don't count some parts of a process including
484 the page tables, kernel stack, struct thread_info, and struct
485 task_struct. This is usually at least 20 KiB of memory that is always
486 resident. SIZE is the virtual size of the process (code+data+stack).
487
488 Processes marked <defunct> are dead processes (so-called "zombies")
489 that remain because their parent has not destroyed them properly.
490 These processes will be destroyed by init(8) if the parent process
491 exits.
492
493 If the length of the username is greater than the length of the display
494 column, the username will be truncated. See the -o and -O formatting
495 options to customize length.
496
497 Commands options such as ps -aux are not recommended as it is a
498 confusion of two different standards. According to the POSIX and UNIX
499 standards, the above command asks to display all processes with a TTY
500 (generally the commands users are running) plus all processes owned by
501 a user named "x". If that user doesn't exist, then ps will assume you
502 really meant "ps aux".
503
505 The sum of these values is displayed in the "F" column, which is
506 provided by the flags output specifier:
507
508 1 forked but didn't exec
509 4 used super-user privileges
510
512 Here are the different values that the s, stat and state output
513 specifiers (header "STAT" or "S") will display to describe the state of
514 a process:
515
516 D uninterruptible sleep (usually IO)
517 I Idle kernel thread
518 R running or runnable (on run queue)
519 S interruptible sleep (waiting for an event to complete)
520 T stopped by job control signal
521 t stopped by debugger during the tracing
522 W paging (not valid since the 2.6.xx kernel)
523 X dead (should never be seen)
524 Z defunct ("zombie") process, terminated but not reaped by
525 its parent
526
527 For BSD formats and when the stat keyword is used, additional
528 characters may be displayed:
529
530 < high-priority (not nice to other users)
531 N low-priority (nice to other users)
532 L has pages locked into memory (for real-time and custom IO)
533 s is a session leader
534 l is multi-threaded (using CLONE_THREAD, like NPTL pthreads
535 do)
536 + is in the foreground process group
537
539 These keys are used by the BSD O option (when it is used for sorting).
540 The GNU --sort option doesn't use these keys, but the specifiers
541 described below in the STANDARD FORMAT SPECIFIERS section. Note that
542 the values used in sorting are the internal values ps uses and not the
543 "cooked" values used in some of the output format fields (e.g. sorting
544 on tty will sort into device number, not according to the terminal name
545 displayed). Pipe ps output into the sort(1) command if you want to
546 sort the cooked values.
547
548 KEY LONG DESCRIPTION
549 c cmd simple name of executable
550 C pcpu cpu utilization
551 f flags flags as in long format F field
552 g pgrp process group ID
553 G tpgid controlling tty process group ID
554 j cutime cumulative user time
555 J cstime cumulative system time
556 k utime user time
557 m min_flt number of minor page faults
558 M maj_flt number of major page faults
559 n cmin_flt cumulative minor page faults
560 N cmaj_flt cumulative major page faults
561 o session session ID
562 p pid process ID
563 P ppid parent process ID
564 r rss resident set size
565 R resident resident pages
566 s size memory size in kilobytes
567 S share amount of shared pages
568 t tty the device number of the controlling tty
569 T start_time time process was started
570 U uid user ID number
571 u user user name
572 v vsize total VM size in KiB
573 y priority kernel scheduling priority
574
576 This ps supports AIX format descriptors, which work somewhat like the
577 formatting codes of printf(1) and printf(3). For example, the normal
578 default output can be produced with this: ps -eo "%p %y %x %c". The
579 NORMAL codes are described in the next section.
580
581 CODE NORMAL HEADER
582 %C pcpu %CPU
583 %G group GROUP
584 %P ppid PPID
585 %U user USER
586 %a args COMMAND
587 %c comm COMMAND
588 %g rgroup RGROUP
589 %n nice NI
590 %p pid PID
591 %r pgid PGID
592 %t etime ELAPSED
593 %u ruser RUSER
594 %x time TIME
595 %y tty TTY
596 %z vsz VSZ
597
599 Here are the different keywords that may be used to control the output
600 format (e.g. with option -o) or to sort the selected processes with the
601 GNU-style --sort option.
602
603 For example: ps -eo pid,user,args --sort user
604
605 This version of ps tries to recognize most of the keywords used in
606 other implementations of ps.
607
608 The following user-defined format specifiers may contain spaces:
609 args, cmd, comm, command, fname, ucmd, ucomm, lstart, bsdstart, start.
610
611 Some keywords may not be available for sorting.
612
613
614 CODE HEADER DESCRIPTION
615
616
617 %cpu %CPU cpu utilization of the process in "##.#" format.
618 Currently, it is the CPU time used divided by the
619 time the process has been running
620 (cputime/realtime ratio), expressed as a
621 percentage. It will not add up to 100% unless
622 you are lucky. (alias pcpu).
623
624 %mem %MEM ratio of the process's resident set size to the
625 physical memory on the machine, expressed as a
626 percentage. (alias pmem).
627
628 args COMMAND command with all its arguments as a string.
629 Modifications to the arguments may be shown. The
630 output in this column may contain spaces. A
631 process marked <defunct> is partly dead, waiting
632 to be fully destroyed by its parent. Sometimes
633 the process args will be unavailable; when this
634 happens, ps will instead print the executable
635 name in brackets. (alias cmd, command). See
636 also the comm format keyword, the -f option, and
637 the c option.
638 When specified last, this column will extend to
639 the edge of the display. If ps can not determine
640 display width, as when output is redirected
641 (piped) into a file or another command, the
642 output width is undefined (it may be 80,
643 unlimited, determined by the TERM variable, and
644 so on). The COLUMNS environment variable or
645 --cols option may be used to exactly determine
646 the width in this case. The w or -w option may
647 be also be used to adjust width.
648
649 blocked BLOCKED mask of the blocked signals, see signal(7).
650 According to the width of the field, a 32 or
651 64-bit mask in hexadecimal format is displayed.
652 (alias sig_block, sigmask).
653
654 bsdstart START time the command started. If the process was
655 started less than 24 hours ago, the output format
656 is " HH:MM", else it is " Mmm:SS" (where Mmm is
657 the three letters of the month). See also
658 lstart, start, start_time, and stime.
659
660 bsdtime TIME accumulated cpu time, user + system. The display
661 format is usually "MMM:SS", but can be shifted to
662 the right if the process used more than 999
663 minutes of cpu time.
664
665 c C processor utilization. Currently, this is the
666 integer value of the percent usage over the
667 lifetime of the process. (see %cpu).
668
669 caught CAUGHT mask of the caught signals, see signal(7).
670 According to the width of the field, a 32 or 64
671 bits mask in hexadecimal format is displayed.
672 (alias sig_catch, sigcatch).
673
674 cgname CGNAME display name of control groups to which the
675 process belongs.
676
677 cgroup CGROUP display control groups to which the process
678 belongs.
679
680
681
682
683
684
685 class CLS scheduling class of the process. (alias
686 policy, cls). Field's possible values are:
687
688 - not reported
689 TS SCHED_OTHER
690 FF SCHED_FIFO
691 RR SCHED_RR
692 B SCHED_BATCH
693 ISO SCHED_ISO
694 IDL SCHED_IDLE
695 DLN SCHED_DEADLINE
696 ? unknown value
697
698 cls CLS scheduling class of the process. (alias
699 policy, cls). Field's possible values are:
700
701 - not reported
702 TS SCHED_OTHER
703 FF SCHED_FIFO
704 RR SCHED_RR
705 B SCHED_BATCH
706 ISO SCHED_ISO
707 IDL SCHED_IDLE
708 DLN SCHED_DEADLINE
709 ? unknown value
710
711 cmd CMD see args. (alias args, command).
712
713 comm COMMAND command name (only the executable name).
714 Modifications to the command name will not be
715 shown. A process marked <defunct> is partly
716 dead, waiting to be fully destroyed by its
717 parent. The output in this column may contain
718 spaces. (alias ucmd, ucomm). See also the args
719 format keyword, the -f option, and the c option.
720 When specified last, this column will extend to
721 the edge of the display. If ps can not determine
722 display width, as when output is redirected
723 (piped) into a file or another command, the
724 output width is undefined (it may be 80,
725 unlimited, determined by the TERM variable, and
726 so on). The COLUMNS environment variable or
727 --cols option may be used to exactly determine
728 the width in this case. The w or -w option may
729 be also be used to adjust width.
730
731 command COMMAND See args. (alias args, command).
732
733 cp CP per-mill (tenths of a percent) CPU usage. (see
734 %cpu).
735
736 cputime TIME cumulative CPU time, "[DD-]hh:mm:ss" format.
737 (alias time).
738
739 cputimes TIME cumulative CPU time in seconds (alias times).
740
741 drs DRS data resident set size, the amount of physical
742 memory devoted to other than executable code.
743
744 egid EGID effective group ID number of the process as a
745 decimal integer. (alias gid).
746
747 egroup EGROUP effective group ID of the process. This will be
748 the textual group ID, if it can be obtained and
749 the field width permits, or a decimal
750 representation otherwise. (alias group).
751
752 eip EIP instruction pointer.
753
754
755 esp ESP stack pointer.
756
757 etime ELAPSED elapsed time since the process was started, in
758 the form [[DD-]hh:]mm:ss.
759
760 etimes ELAPSED elapsed time since the process was started, in
761 seconds.
762
763 euid EUID effective user ID (alias uid).
764
765 euser EUSER effective user name. This will be the textual
766 user ID, if it can be obtained and the field
767 width permits, or a decimal representation
768 otherwise. The n option can be used to force the
769 decimal representation. (alias uname, user).
770
771 f F flags associated with the process, see the
772 PROCESS FLAGS section. (alias flag, flags).
773
774 fgid FGID filesystem access group ID. (alias fsgid).
775
776 fgroup FGROUP filesystem access group ID. This will be the
777 textual group ID, if it can be obtained and the
778 field width permits, or a decimal representation
779 otherwise. (alias fsgroup).
780
781 flag F see f. (alias f, flags).
782
783 flags F see f. (alias f, flag).
784
785 fname COMMAND first 8 bytes of the base name of the process's
786 executable file. The output in this column may
787 contain spaces.
788
789 fuid FUID filesystem access user ID. (alias fsuid).
790
791 fuser FUSER filesystem access user ID. This will be the
792 textual user ID, if it can be obtained and the
793 field width permits, or a decimal representation
794 otherwise.
795
796 gid GID see egid. (alias egid).
797
798 group GROUP see egroup. (alias egroup).
799
800 ignored IGNORED mask of the ignored signals, see signal(7).
801 According to the width of the field, a 32 or 64
802 bits mask in hexadecimal format is displayed.
803 (alias sig_ignore, sigignore).
804
805 ipcns IPCNS Unique inode number describing the namespace the
806 process belongs to. See namespaces(7).
807
808 label LABEL security label, most commonly used for SELinux
809 context data. This is for the Mandatory Access
810 Control ("MAC") found on high-security systems.
811
812 lstart STARTED time the command started. See also
813 bsdstart, start, start_time, and stime.
814
815 lsession SESSION displays the login session identifier of a
816 process, if systemd support has been included.
817
818 luid LUID displays Login ID associated with a process.
819
820
821
822
823 lwp LWP light weight process (thread) ID of the
824 dispatchable entity (alias spid, tid). See tid
825 for additional information.
826
827 lxc LXC The name of the lxc container within which a task
828 is running. If a process is not running inside a
829 container, a dash ('-') will be shown.
830
831 machine MACHINE displays the machine name for processes assigned
832 to VM or container, if systemd support has been
833 included.
834
835 maj_flt MAJFLT The number of major page faults that have
836 occurred with this process.
837
838 min_flt MINFLT The number of minor page faults that have
839 occurred with this process.
840
841 mntns MNTNS Unique inode number describing the namespace the
842 process belongs to. See namespaces(7).
843
844 netns NETNS Unique inode number describing the namespace the
845 process belongs to. See namespaces(7).
846
847 ni NI nice value. This ranges from 19 (nicest) to -20
848 (not nice to others), see nice(1). (alias nice).
849
850 nice NI see ni.(alias ni).
851
852 nlwp NLWP number of lwps (threads) in the process. (alias
853 thcount).
854
855 numa NUMA The node assocated with the most recently used
856 processor. A -1 means that NUMA information is
857 unavailable.
858
859 nwchan WCHAN address of the kernel function where the process
860 is sleeping (use wchan if you want the kernel
861 function name). Running tasks will display a
862 dash ('-') in this column.
863
864 ouid OWNER displays the Unix user identifier of the owner of
865 the session of a process, if systemd support has
866 been included.
867
868 pcpu %CPU see %cpu. (alias %cpu).
869
870 pending PENDING mask of the pending signals. See signal(7).
871 Signals pending on the process are distinct from
872 signals pending on individual threads. Use the m
873 option or the -m option to see both. According
874 to the width of the field, a 32 or 64 bits mask
875 in hexadecimal format is displayed. (alias sig).
876
877 pgid PGID process group ID or, equivalently, the process ID
878 of the process group leader. (alias pgrp).
879
880 pgrp PGRP see pgid. (alias pgid).
881
882 pid PID a number representing the process ID (alias
883 tgid).
884
885 pidns PIDNS Unique inode number describing the namespace the
886 process belongs to. See namespaces(7).
887
888 pmem %MEM see %mem. (alias %mem).
889
890
891
892 policy POL scheduling class of the process. (alias
893 class, cls). Possible values are:
894
895 - not reported
896 TS SCHED_OTHER
897 FF SCHED_FIFO
898 RR SCHED_RR
899 B SCHED_BATCH
900 ISO SCHED_ISO
901 IDL SCHED_IDLE
902 DLN SCHED_DEADLINE
903 ? unknown value
904
905 ppid PPID parent process ID.
906
907 pri PRI priority of the process. Higher number means
908 lower priority.
909
910 psr PSR processor that process is currently assigned to.
911
912 rgid RGID real group ID.
913
914 rgroup RGROUP real group name. This will be the textual group
915 ID, if it can be obtained and the field width
916 permits, or a decimal representation otherwise.
917
918 rss RSS resident set size, the non-swapped physical
919 memory that a task has used (in kiloBytes).
920 (alias rssize, rsz).
921
922 rssize RSS see rss. (alias rss, rsz).
923
924 rsz RSZ see rss. (alias rss, rssize).
925
926 rtprio RTPRIO realtime priority.
927
928 ruid RUID real user ID.
929
930 ruser RUSER real user ID. This will be the textual user ID,
931 if it can be obtained and the field width
932 permits, or a decimal representation otherwise.
933
934 s S minimal state display (one character). See
935 section PROCESS STATE CODES for the different
936 values. See also stat if you want additional
937 information displayed. (alias state).
938
939 sched SCH scheduling policy of the process. The policies
940 SCHED_OTHER (SCHED_NORMAL), SCHED_FIFO, SCHED_RR,
941 SCHED_BATCH, SCHED_ISO, SCHED_IDLE and
942 SCHED_DEADLINE are respectively displayed as 0,
943 1, 2, 3, 4, 5 and 6.
944
945 seat SEAT displays the identifier associated with all
946 hardware devices assigned to a specific
947 workplace, if systemd support has been included.
948
949 sess SESS session ID or, equivalently, the process ID of
950 the session leader. (alias session, sid).
951
952 sgi_p P processor that the process is currently executing
953 on. Displays "*" if the process is not currently
954 running or runnable.
955
956 sgid SGID saved group ID. (alias svgid).
957
958
959
960
961 sgroup SGROUP saved group name. This will be the textual group
962 ID, if it can be obtained and the field width
963 permits, or a decimal representation otherwise.
964
965 sid SID see sess. (alias sess, session).
966
967 sig PENDING see pending. (alias pending, sig_pend).
968
969 sigcatch CAUGHT see caught. (alias caught, sig_catch).
970
971 sigignore IGNORED see ignored. (alias ignored, sig_ignore).
972
973 sigmask BLOCKED see blocked. (alias blocked, sig_block).
974
975 size SIZE approximate amount of swap space that would be
976 required if the process were to dirty all
977 writable pages and then be swapped out. This
978 number is very rough!
979
980 slice SLICE displays the slice unit which a process belongs
981 to, if systemd support has been included.
982
983 spid SPID see lwp. (alias lwp, tid).
984
985 stackp STACKP address of the bottom (start) of stack for the
986 process.
987
988 start STARTED time the command started. If the process was
989 started less than 24 hours ago, the output format
990 is "HH:MM:SS", else it is " Mmm dd" (where Mmm
991 is a three-letter month name). See also
992 lstart, bsdstart, start_time, and stime.
993
994 start_time START starting time or date of the process. Only the
995 year will be displayed if the process was not
996 started the same year ps was invoked, or "MmmDD"
997 if it was not started the same day, or "HH:MM"
998 otherwise. See also bsdstart, start, lstart,
999 and stime.
1000
1001 stat STAT multi-character process state. See section
1002 PROCESS STATE CODES for the different values
1003 meaning. See also s and state if you just want
1004 the first character displayed.
1005
1006 state S see s. (alias s).
1007
1008 suid SUID saved user ID. (alias svuid).
1009
1010 supgid SUPGID group ids of supplementary groups, if any. See
1011 getgroups(2).
1012
1013 supgrp SUPGRP group names of supplementary groups, if any. See
1014 getgroups(2).
1015
1016 suser SUSER saved user name. This will be the textual user
1017 ID, if it can be obtained and the field width
1018 permits, or a decimal representation otherwise.
1019 (alias svuser).
1020
1021 svgid SVGID see sgid. (alias sgid).
1022
1023 svuid SVUID see suid. (alias suid).
1024
1025 sz SZ size in physical pages of the core image of the
1026 process. This includes text, data, and stack
1027 space. Device mappings are currently excluded;
1028 this is subject to change. See vsz and rss.
1029
1030
1031 tgid TGID a number representing the thread group to which a
1032 task belongs (alias pid). It is the process ID
1033 of the thread group leader.
1034
1035 thcount THCNT see nlwp. (alias nlwp). number of kernel
1036 threads owned by the process.
1037
1038 tid TID the unique number representing a dispatchable
1039 entity (alias lwp, spid). This value may also
1040 appear as: a process ID (pid); a process group ID
1041 (pgrp); a session ID for the session leader
1042 (sid); a thread group ID for the thread group
1043 leader (tgid); and a tty process group ID for the
1044 process group leader (tpgid).
1045
1046 time TIME cumulative CPU time, "[DD-]HH:MM:SS" format.
1047 (alias cputime).
1048
1049 times TIME cumulative CPU time in seconds (alias cputimes).
1050
1051 tname TTY controlling tty (terminal). (alias tt, tty).
1052
1053 tpgid TPGID ID of the foreground process group on the tty
1054 (terminal) that the process is connected to, or
1055 -1 if the process is not connected to a tty.
1056
1057 trs TRS text resident set size, the amount of physical
1058 memory devoted to executable code.
1059
1060 tt TT controlling tty (terminal). (alias tname, tty).
1061
1062 tty TT controlling tty (terminal). (alias tname, tt).
1063
1064 ucmd CMD see comm. (alias comm, ucomm).
1065
1066 ucomm COMMAND see comm. (alias comm, ucmd).
1067
1068 uid UID see euid. (alias euid).
1069
1070 uname USER see euser. (alias euser, user).
1071
1072 unit UNIT displays unit which a process belongs to, if
1073 systemd support has been included.
1074
1075 user USER see euser. (alias euser, uname).
1076
1077 userns USERNS Unique inode number describing the namespace the
1078 process belongs to. See namespaces(7).
1079
1080 utsns UTSNS Unique inode number describing the namespace the
1081 process belongs to. See namespaces(7).
1082
1083 uunit UUNIT displays user unit which a process belongs to, if
1084 systemd support has been included.
1085
1086 vsize VSZ see vsz. (alias vsz).
1087
1088 vsz VSZ virtual memory size of the process in KiB
1089 (1024-byte units). Device mappings are currently
1090 excluded; this is subject to change. (alias
1091 vsize).
1092
1093 wchan WCHAN name of the kernel function in which the process
1094 is sleeping, a "-" if the process is running, or
1095 a "*" if the process is multi-threaded and ps is
1096 not displaying threads.
1097
1098
1100 The following environment variables could affect ps:
1101
1102 COLUMNS
1103 Override default display width.
1104
1105 LINES
1106 Override default display height.
1107
1108 PS_PERSONALITY
1109 Set to one of posix, old, linux, bsd, sun, digital... (see section
1110 PERSONALITY below).
1111
1112 CMD_ENV
1113 Set to one of posix, old, linux, bsd, sun, digital... (see section
1114 PERSONALITY below).
1115
1116 I_WANT_A_BROKEN_PS
1117 Force obsolete command line interpretation.
1118
1119 LC_TIME
1120 Date format.
1121
1122 PS_COLORS
1123 Not currently supported.
1124
1125 PS_FORMAT
1126 Default output format override. You may set this to a format string
1127 of the type used for the -o option. The DefSysV and DefBSD values
1128 are particularly useful.
1129
1130 POSIXLY_CORRECT
1131 Don't find excuses to ignore bad "features".
1132
1133 POSIX2
1134 When set to "on", acts as POSIXLY_CORRECT.
1135
1136 UNIX95
1137 Don't find excuses to ignore bad "features".
1138
1139 _XPG
1140 Cancel CMD_ENV=irix non-standard behavior.
1141
1142 In general, it is a bad idea to set these variables. The one exception
1143 is CMD_ENV or PS_PERSONALITY, which could be set to Linux for normal
1144 systems. Without that setting, ps follows the useless and bad parts of
1145 the Unix98 standard.
1146
1148 390 like the OS/390 OpenEdition ps
1149 aix like AIX ps
1150 bsd like FreeBSD ps (totally non-standard)
1151 compaq like Digital Unix ps
1152 debian like the old Debian ps
1153 digital like Tru64 (was Digital Unix, was OSF/1) ps
1154 gnu like the old Debian ps
1155 hp like HP-UX ps
1156 hpux like HP-UX ps
1157 irix like Irix ps
1158 linux ***** recommended *****
1159 old like the original Linux ps (totally non-standard)
1160 os390 like OS/390 Open Edition ps
1161 posix standard
1162 s390 like OS/390 Open Edition ps
1163 sco like SCO ps
1164 sgi like Irix ps
1165 solaris2 like Solaris 2+ (SunOS 5) ps
1166 sunos4 like SunOS 4 (Solaris 1) ps (totally non-standard)
1167
1168 svr4 standard
1169 sysv standard
1170 tru64 like Tru64 (was Digital Unix, was OSF/1) ps
1171 unix standard
1172 unix95 standard
1173 unix98 standard
1174
1176 pgrep(1), pstree(1), top(1), proc(5).
1177
1179 This ps conforms to:
1180
1181 1 Version 2 of the Single Unix Specification
1182 2 The Open Group Technical Standard Base Specifications, Issue 6
1183 3 IEEE Std 1003.1, 2004 Edition
1184 4 X/Open System Interfaces Extension [UP XSI]
1185 5 ISO/IEC 9945:2003
1186
1188 ps was originally written by Branko Lankester ⟨lankeste@fwi.uva.nl⟩.
1189 Michael K. Johnson ⟨johnsonm@redhat.com⟩ re-wrote it significantly to
1190 use the proc filesystem, changing a few things in the process. Michael
1191 Shields ⟨mjshield@nyx.cs.du.edu⟩ added the pid-list feature. Charles
1192 Blake ⟨cblake@bbn.com⟩ added multi-level sorting, the dirent-style
1193 library, the device name-to-number mmaped database, the approximate
1194 binary search directly on System.map, and many code and documentation
1195 cleanups. David Mossberger-Tang wrote the generic BFD support for
1196 psupdate. Albert Cahalan ⟨albert@users.sf.net⟩ rewrote ps for full
1197 Unix98 and BSD support, along with some ugly hacks for obsolete and
1198 foreign syntax.
1199
1200 Please send bug reports to ⟨procps@freelists.org⟩. No subscription is
1201 required or suggested.
1202
1203
1204
1205procps-ng 2018-01-13 PS(1)