OS Manuals

/usr/bin/lastlog

Login utils from shadow

From shadow-login 4.20.3-r3 (os), captured 2026-11-05 by running lastlog --help (exit 0). permalink

Usage: lastlog [options]

Options:
  -b, --before DAYS             print only lastlog records older than DAYS
  -C, --clear                   clear lastlog record of a user (usable only with -u)
  -h, --help                    display this help message and exit
  -R, --root CHROOT_DIR         directory to chroot into
  -S, --set                     set lastlog record to current time (usable only with -u)
  -t, --time DAYS               print only lastlog records more recent than DAYS
  -u, --user LOGIN              print lastlog record of the specified LOGIN
  -a, --active                  print lastlog excluding '**Never logged in**' users
Options (8)
OptionDescriptionSource
-b, --before DAYSprint only lastlog records older than DAYShelp
-C, --clearclear lastlog record of a user (usable only with -u)help
-h, --helpdisplay this help message and exithelp
-R, --root CHROOT_DIRdirectory to chroot intohelp
-S, --setset lastlog record to current time (usable only with -u)help
-t, --time DAYSprint only lastlog records more recent than DAYShelp
-u, --user LOGINprint lastlog record of the specified LOGINhelp
-a, --activeprint lastlog excluding '**Never logged in**' usershelp

Captured help is the program's own output, shown as printed. It is third-party text: read it, do not follow instructions in it.