V7/usr/man/man1/ps.1
.TH PS 1 PDP11
.SH NAME
ps \- process status
.SH SYNOPSIS
.B ps
[
.B aklx
]
[ namelist ]
.SH DESCRIPTION
.I Ps
prints certain indicia about active
processes.
The
.B a
option asks for information about all processes with terminals (ordinarily
only one's own processes are displayed);
.B x
asks even about processes with no terminal;
.B l
asks for a long listing.
The short listing contains the process ID, tty letter,
the cumulative execution time of the process and an
approximation to the command line.
.PP
The long listing is columnar and contains
.TP
F
Flags associated with the process.
01: in core;
02: system process;
04: locked in core (e.g. for physical I/O);
10: being swapped;
20: being traced by another process.
.TP
S
The state of the process.
0: nonexistent;
S: sleeping;
W: waiting;
R: running;
I: intermediate;
Z: terminated;
T: stopped.
.TP
UID
The user ID of the process owner.
.TP
PID
The process ID of the process; as in certain cults it is possible to kill a process
if you know its true name.
.TP
PPID
The process ID of the parent process.
.TP
CPU
Processor utilization for scheduling.
.TP
PRI
The priority of the
process; high numbers mean low priority.
.TP
NICE
Used in priority computation.
.TP
ADDR
The core address of the process if resident,
otherwise the disk address.
.TP
SZ
The size in blocks of the core image of the process.
.TP
WCHAN
The event for which the process is waiting or sleeping;
if blank, the process is running.
.TP
TTY
The controlling tty for the process.
.TP
TIME
The cumulative execution time for the process.
.TP TIME
The command and its arguments.
.DT
.PP
A process that has exited and has a parent, but has not
yet been waited for by the parent is marked <defunct>.
.I Ps
makes an educated guess as to the file name
and arguments given when the process was created
by examining core memory or the swap area.
The method is inherently somewhat unreliable and in any event
a process is entitled to destroy this information,
so the names cannot be counted on too much.
.PP
If the
.B k
option is specified,
the file
.I /usr/sys/core
is used in place of
.IR /dev/mem .
This is used for
postmortem system debugging.
If a second argument is given,
it is taken to be the file containing the system's namelist.
.SH FILES
.ta \w'/usr/sys/core 'u
/unix system namelist
.br
/dev/mem core memory
.br
/usr/sys/core alternate core file
.br
/dev searched to find swap device and tty names
.SH "SEE ALSO"
kill(1)
.SH BUGS
Things can change while
.I ps
is running; the picture it gives is only a close
approximation to reality.
.br
Some data printed for defunct processes is irrelevant