Linux Commands Reference - Complete Linux Command Guide

Comprehensive Linux command reference with 150+ commands. Search, filter by category, and view detailed usage examples.

Share
Back to commands

lastlog

Show most recent login for all users

Syntax

lastlog [OPTION]...

Common Options

-uShow specific user
-tShow logins within N days
-bShow logins before N days

Common Examples

lastlog

Show all users login info

lastlog -u username

Show specific user

lastlog -t 7

Show logins within 7 days

lastlog -b 30

Show logins before 30 days

Related Commands

Related Tools

More Code & Dev Tools