3 .TH LAST,LASTB 1 "Jul 29, 1999" "" "Linux System Administrator's Manual"
7 last, lastb \- show listing of last logged in users
14 .RB "[ \-\fBn\fP \fInum\fP ]"
16 .RB "[ \-\fBf\fP \fIfile\fP ]"
23 .RB "[ \-\fBn\fP \fInum\fP ]"
24 .RB "[ \-\fBf\fP \fIfile\fP ]"
32 searches back through the file \fB/var/log/wtmp\fP (or the file
33 designated by the \fB\-f\fP flag) and displays a list of all
34 users logged in (and out) since that file was created. Names of users
35 and tty's can be given, in which case \fBlast\fP will show only those entries
36 matching the arguments. Names of ttys can be abbreviated, thus \fBlast
37 0\fP is the same as \fBlast tty0\fP.
39 When \fBlast\fP catches a \s-2SIGINT\s0 signal (generated by the interrupt key,
40 usually control-C) or a \s-2SIGQUIT\s0 signal (generated by the quit key,
41 usually control-\e), \fBlast\fP will show how far it has searched through the
42 file; in the case of the \s-2SIGINT\s0 signal \fBlast\fP will then terminate.
44 The pseudo user \fBreboot\fP logs in each time the system is rebooted.
45 Thus \fBlast reboot\fP will show a log of all reboots since the log file
48 \fBLastb\fP is the same as \fBlast\fP, except that by default it shows a log
49 of the file \fB/var/log/btmp\fP, which contains all the bad login attempts.
54 This is a count telling \fBlast\fP how many lines to show.
55 .IP "\fB\-n\fP \fInum\fP"
58 Suppresses the display of the hostname field.
60 Display the hostname in the last column. Useful in combination
63 For non-local logins, Linux stores not only the host name of the remote
64 host but its IP number as well. This option translates the IP number
67 This option is like \fB-d\fP in that it displays the IP number of the remote
68 host, but it displays the IP number in numbers-and-dots notation.
70 Read an old-type wtmp file (written by linux-libc5 applications).
72 Display the system shutdown entries and run level changes.
75 The files \fIwtmp\fP and \fIbtmp\fP might not be found. The system only
76 logs information in these files if they are present. This is a local
77 configuration issue. If you want the files to be used, they can be
78 created with a simple \fBtouch\fP(1) command (for example,
79 \fItouch /var/log/wtmp\fP).
88 Miquel van Smoorenburg, miquels@cistron.nl