w.1 2.56 KB
Newer Older
csmall's avatar
csmall committed
1 2
.\"             -*-Nroff-*-
.\"
Jaromir Capik's avatar
Jaromir Capik committed
3
.TH W "1" "May 2012" "procps-ng" "User Commands"
csmall's avatar
csmall committed
4 5 6
.SH NAME
w \- Show who is logged on and what they are doing.
.SH SYNOPSIS
Jan Görig's avatar
Jan Görig committed
7
.B w
8
[\fIoptions\fR] \fIuser\fR [...]
csmall's avatar
csmall committed
9
.SH DESCRIPTION
Jan Görig's avatar
Jan Görig committed
10
.B w
11 12 13 14 15 16 17 18 19 20 21 22 23
displays information about the users currently on the machine, and their
processes.  The header shows, in this order, the current time, how long the
system has been running, how many users are currently logged on, and the
system load averages for the past 1, 5, and 15 minutes.
.PP
The following entries are displayed for each user: login name, the tty name,
the remote host, login time, idle time, JCPU, PCPU, and the command line of
their current process.
.PP
The JCPU time is the time used by all processes attached to the tty.  It does
not include past background jobs, but does include currently running
background jobs.
.PP
csmall's avatar
csmall committed
24 25 26
The PCPU time is the time used by the current process, named in the "what"
field.
.SH "COMMAND\-LINE OPTIONS"
27 28
.TP
\fB\-h\fR, \fB\-\-no\-header\fR
csmall's avatar
csmall committed
29
Don't print the header.
30 31 32 33 34 35 36 37 38 39
.TP
\fB\-u\fR, \fB\-\-no\-current\fR
Ignores the username while figuring out the
current process and cpu times.  To demonstrate this, do a "su" and do a "w"
and a "w \-u".
.TP
\fB\-s\fR, \fB\-\-short\fR
Use the short format.  Don't print the login time, JCPU or PCPU times.
.TP
\fB\-f\fR, \fB\-\-from\fR
csmall's avatar
csmall committed
40 41
Toggle printing the
.B from
42
(remote hostname) field.  The default as released is for the
csmall's avatar
csmall committed
43
.B from
44 45
field to not be printed, although your system administrator or distribution
maintainer may have compiled a version in which the
csmall's avatar
csmall committed
46 47
.B from
field is shown by default.
48 49 50 51
.TP
\fB\-\-help\fR
Display help text and exit.
.TP
52
\fB\-i\fR, \fB\-\-ip\-addr\fR
Jaromir Capik's avatar
Jaromir Capik committed
53 54
Display IP address instead of hostname for \fBfrom\fR field.
.TP
55
\fB\-V\fR, \fB\-\-version\fR
csmall's avatar
csmall committed
56
Display version information.
57 58 59 60
.TP
\fB\-o\fR, \fB\-\-old\-style\fR
Old style output.  Prints blank space for idle times less than one minute.
.TP
csmall's avatar
csmall committed
61 62
.B "user "
Show information about the specified user only.
63 64 65
.SH ENVIRONMENT
.TP
PROCPS_USERLEN
66
Override the default width of the username column.  Defaults to 8.
67 68
.TP
PROCPS_FROMLEN
69
Override the default width of the from column.  Defaults to 16.
csmall's avatar
csmall committed
70 71
.SH FILES
.TP
albert's avatar
albert committed
72
.I /var/run/utmp
csmall's avatar
csmall committed
73 74 75 76 77 78 79 80 81 82 83 84 85
information about who is currently logged on
.TP
.I /proc
process information
.SH "SEE ALSO"
.BR free (1),
.BR ps (1),
.BR top (1),
.BR uptime (1),
.BR utmp (5),
.BR who (1)
.SH AUTHORS
.B w
86
was re-written almost entirely by Charles Blake, based on the version by
87
.UR greenfie@\:gauss.\:rutgers.\:edu
88 89 90
Larry Greenfield
.UE
and
91
.UR johnsonm@\:redhat.\:com
92 93 94 95
Michael K. Johnson
.UE
.SH "REPORTING BUGS"
Please send bug reports to
96
.UR procps@freelists.org
97
.UE