annotate head/usr.bin/who/who.1 @ 373:a085b3559102

Update to FreeBSD-HEAD @232391
author ray@terran.dlink.ua
date Fri, 02 Mar 2012 17:02:21 +0200
parents 5c5ea52c940d
children 49f3e3227aef
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
1 .\" Copyright (c) 1986, 1991, 1993
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
2 .\" The Regents of the University of California. All rights reserved.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
3 .\"
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
4 .\" Redistribution and use in source and binary forms, with or without
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
5 .\" modification, are permitted provided that the following conditions
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
6 .\" are met:
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
7 .\" 1. Redistributions of source code must retain the above copyright
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
8 .\" notice, this list of conditions and the following disclaimer.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
9 .\" 2. Redistributions in binary form must reproduce the above copyright
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
10 .\" notice, this list of conditions and the following disclaimer in the
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
11 .\" documentation and/or other materials provided with the distribution.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
12 .\" 4. Neither the name of the University nor the names of its contributors
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
13 .\" may be used to endorse or promote products derived from this software
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
14 .\" without specific prior written permission.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
15 .\"
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
16 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
17 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
18 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
19 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
20 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
21 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
22 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
23 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
24 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
25 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
26 .\" SUCH DAMAGE.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
27 .\"
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
28 .\" @(#)who.1 8.2 (Berkeley) 12/30/93
373
a085b3559102 Update to FreeBSD-HEAD @232391
ray@terran.dlink.ua
parents: 221
diff changeset
29 .\" $FreeBSD: head/usr.bin/who/who.1 231536 2012-02-11 21:49:23Z ed $
1
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
30 .\"
373
a085b3559102 Update to FreeBSD-HEAD @232391
ray@terran.dlink.ua
parents: 221
diff changeset
31 .Dd February 11, 2012
1
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
32 .Dt WHO 1
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
33 .Os
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
34 .Sh NAME
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
35 .Nm who
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
36 .Nd display who is on the system
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
37 .Sh SYNOPSIS
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
38 .Nm
373
a085b3559102 Update to FreeBSD-HEAD @232391
ray@terran.dlink.ua
parents: 221
diff changeset
39 .Op Fl abHmqsTu
1
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
40 .Op Cm am I
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
41 .Op Ar file
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
42 .Sh DESCRIPTION
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
43 The
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
44 .Nm
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
45 utility displays information about currently logged in users.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
46 By default, this includes the login name, tty name, date and time of login and
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
47 remote hostname if not local.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
48 .Pp
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
49 The options are as follows:
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
50 .Bl -tag -width indent
373
a085b3559102 Update to FreeBSD-HEAD @232391
ray@terran.dlink.ua
parents: 221
diff changeset
51 .It Fl a
a085b3559102 Update to FreeBSD-HEAD @232391
ray@terran.dlink.ua
parents: 221
diff changeset
52 Equivalent to
a085b3559102 Update to FreeBSD-HEAD @232391
ray@terran.dlink.ua
parents: 221
diff changeset
53 .Fl bTu ,
a085b3559102 Update to FreeBSD-HEAD @232391
ray@terran.dlink.ua
parents: 221
diff changeset
54 with the exception that output isn't restricted to the time and date of
a085b3559102 Update to FreeBSD-HEAD @232391
ray@terran.dlink.ua
parents: 221
diff changeset
55 the last system reboot.
221
5c5ea52c940d FreeBSD HEAD @svn 226966r.
ray@terran.dlink.ua
parents: 85
diff changeset
56 .It Fl b
5c5ea52c940d FreeBSD HEAD @svn 226966r.
ray@terran.dlink.ua
parents: 85
diff changeset
57 Write the time and date of the last system reboot.
1
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
58 .It Fl H
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
59 Write column headings above the output.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
60 .It Fl m
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
61 Show information about the terminal attached to standard input only.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
62 .It Fl q
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
63 .Dq "Quick mode" :
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
64 List the names and number of logged in users in columns.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
65 All other command line options are ignored.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
66 .It Fl s
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
67 Show the name, line and time fields only.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
68 This is the default.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
69 .It Fl T
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
70 Indicate whether each user is accepting messages.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
71 One of the following characters is written:
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
72 .Pp
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
73 .Bl -tag -width 1n -compact
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
74 .It Li +
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
75 User is accepting messages.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
76 .It Li \&-
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
77 User is not accepting messages.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
78 .It Li \&?
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
79 An error occurred.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
80 .El
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
81 .It Fl u
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
82 Show idle time for each user in hours and minutes as
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
83 .Ar hh Ns : Ns Ar mm ,
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
84 .Ql \&.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
85 if the user has been idle less that a minute, and
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
86 .Dq Li old
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
87 if the user has been idle more than 24 hours.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
88 .It Cm am I
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
89 Equivalent to
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
90 .Fl m .
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
91 .El
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
92 .Pp
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
93 By default,
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
94 .Nm
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
95 gathers information from the file
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
96 .Pa /var/run/utx.active .
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
97 An alternate
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
98 .Ar file
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
99 may be specified which is usually
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
100 .Pa /var/log/utx.log
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
101 (or
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
102 .Pa /var/log/utx.log.[0-6]
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
103 depending on site policy as
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
104 .Pa utx.log
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
105 can grow quite large and daily versions may or may not
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
106 be kept around after compression by
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
107 .Xr ac 8 ) .
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
108 The
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
109 .Pa utx.log
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
110 file contains a record of every login, logout,
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
111 crash, shutdown and date change
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
112 since
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
113 .Pa utx.log
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
114 was last truncated or
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
115 created.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
116 .Pp
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
117 If
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
118 .Pa /var/log/utx.log
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
119 is being used as the file, the user name may be empty
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
120 or one of the special characters '|', '}' and '~'.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
121 Logouts produce
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
122 an output line without any user name.
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
123 For more information on the
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
124 special characters, see
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
125 .Xr getutxent 3 .
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
126 .Sh ENVIRONMENT
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
127 The
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
128 .Ev COLUMNS , LANG , LC_ALL
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
129 and
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
130 .Ev LC_TIME
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
131 environment variables affect the execution of
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
132 .Nm
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
133 as described in
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
134 .Xr environ 7 .
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
135 .Sh FILES
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
136 .Bl -tag -width /var/log/utx.log.[0-6] -compact
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
137 .It Pa /var/run/utx.active
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
138 .It Pa /var/log/utx.log
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
139 .It Pa /var/log/utx.log.[0-6]
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
140 .El
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
141 .Sh EXIT STATUS
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
142 .Ex -std
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
143 .Sh SEE ALSO
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
144 .Xr last 1 ,
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
145 .Xr users 1 ,
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
146 .Xr w 1 ,
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
147 .Xr getutxent 3
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
148 .Sh STANDARDS
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
149 The
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
150 .Nm
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
151 utility conforms to
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
152 .St -p1003.1-2001 .
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
153 .Sh HISTORY
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
154 A
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
155 .Nm
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
156 command appeared in
8101a7904232 FreeBSD HEAD @205277
ray@terran.dlink.ua
parents:
diff changeset
157 .At v1 .