• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

last

last

last Indicates last logins of users and ttys.
last [-n] [-f <file>] [-h <host>] [-t <tty>] [<user1>
									<user2> ...]

last lists the sessions of specified users, ttys, and hosts, in reverse time order. Each line of output contains the username, the tty from which the session was conducted, any hostname, the start and stop times for the session, and the duration of the session. If the session is still in progress or was cut short by a crash or shutdown, last indicates that.
-n Limits the report to n lines.
-f <file> Reads <file> instead of the default /var/log/wtmp.
-h <host> Lists sessions from <host>. <host> may be a name or Internet number.
-t <tty> Lists sessions on <tty>. <tty> may be given fully or abbreviated. For example, last -t p3 is equivalent to last -t ttyp3.
If multiple arguments are given, the information that applies to any of the arguments is printed. For example, last root -t console would list all sessions of root as well as all sessions on the console.
The pseudo-user reboot logs in at system reboot, so last reboot gives an indication of the mean time between reboots.



PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint