...
Last searches back through the file /var/log/wtmp (or the file designated by the -f flag) and displays a list of all users logged in (and out) since that file was created.
Lastb
Lastb is the same as last, except that by default it shows a log of the file /var/log/btmp, which contains all the bad login attempts.