Home Explore Blog CI



man-pages

4th chunk of `ps.man`
48b9c81e655157943d33dd7d407c68625af879040eb324090000000100000fa4
 pidlist.

       q pidlist
              Select  by  process  ID  (quick  mode).   Identical  to  -q   and
              --quick-pid.

       -q pidlist
              Select  by  PID  (quick  mode).  This selects the processes whose
              process ID numbers appear in pidlist.  With this option ps  reads
              the  necessary  info  only for the pids listed in the pidlist and
              doesn’t apply additional filtering rules. The order  of  pids  is
              unsorted  and preserved. No additional selection options, sorting
              and forest type listings are allowed in this mode.  Identical  to
              q and --quick-pid.

       --quick-pid pidlist
              Select by process ID (quick mode).  Identical to -q and q.

       -s sesslist
              Select  by session ID.  This selects the processes with a session
              ID specified in sesslist.

       --sid sesslist
              Select by session ID.  Identical to -s.

       t ttylist
              Select by tty.  Nearly identical to -t and --tty, but can also be
              used with an empty ttylist to indicate  the  terminal  associated
              with  ps.   Using the T option is considered cleaner than using t
              with an empty ttylist.

       -t ttylist
              Select by tty.  This selects the processes  associated  with  the
              terminals given in ttylist.  Terminals (ttys, or screens for text
              output) can be specified in several forms: /dev/ttyS1, ttyS1, S1.
              A  plain  "-" may be used to select processes not attached to any
              terminal.

       --tty ttylist
              Select by terminal.  Identical to -t and t.

       U userlist
              Select by effective user ID (EUID) or  name.   This  selects  the
              processes  whose  effective  user name or ID is in userlist.  The
              effective  user  ID  describes  the  user   whose   file   access
              permissions  are used by the process (see geteuid(2)).  Identical
              to -u and --user.

       -U userlist
              Select by real user ID (RUID) or name.  It selects the  processes
              whose  real  user  name  or ID is in the userlist list.  The real
              user  ID  identifies  the  user  who  created  the  process,  see
              getuid(2).

       -u userlist
              Select  by  effective  user  ID (EUID) or name.  This selects the
              processes whose effective user name or ID is in userlist.

              The effective user  ID  describes  the  user  whose  file  access
              permissions  are used by the process (see geteuid(2)).  Identical
              to U and --user.

       --User userlist
              Select by real user ID (RUID) or name.  Identical to -U.

       --user userlist
              Select by effective user ID (EUID) or name.  Identical to -u  and
              U.

OUTPUT FORMAT CONTROL
       These  options  are used to choose the information displayed by ps.  The
       output may differ by personality.

       -c     Show different scheduler information for the -l option.

       --context
              Display security context format (for SELinux).

       -f     Do full-format listing. This option can  be  combined  with  many
              other  UNIX-style  options  to  add  additional columns.  It also
              causes the command arguments to be printed.  When used  with  -L,
              the  NLWP (number of threads) and LWP (thread ID) columns will be
              added.  See the c option, the format keyword args, and the format
              keyword comm.

       -F     Extra full format.  See the -f option, which -F implies.

       --format format
              user-defined format.  Identical to -o and o.

       j      BSD job control format.

       -j     Jobs format.

       l      Display BSD long format.

       -l     Long format.  The -y option is often useful

Title: ps - Process Selection by List (continued) and Output Format Control
Summary
This section continues the explanation of process selection options for `ps`, focusing on selecting by terminal (`-t`, `--tty`, `t`) and user ID, both real (`-U`, `--User`) and effective (`-u`, `U`, `--user`). It also transitions to output format control options, detailing how to customize the information displayed by `ps` using options like `-c`, `--context`, `-f`, `-F`, `--format`, `j`, `-j`, `l`, and `-l`, which control aspects like scheduler information, security context, full format listings, and job control format.