LinuxCommandLibrary

who

Show who is logged on

TLDR

Display the username, line, and time of all currently logged-in sessions

$ who
copy

Display all available information
$ who [[-a|--all]]
copy

Display all available information with table headers
$ who [[-aH|--all --heading]]
copy

SYNOPSIS

who [options] [file]

PARAMETERS

-a, --all
    Print all information

-b, --boot
    Time of last system boot

-H, --heading
    Print column headers

-q, --count
    All login names and count

-r, --runlevel
    Print current runlevel

-u, --users
    List users logged in

am i
    Print info about current user

DESCRIPTION

who displays information about users currently logged into the system. It shows usernames, terminal lines, login times, and remote hosts. who reads the utmp file to get login information.

CAVEATS

Shows terminal sessions, may not include all remote sessions. Information comes from utmp/wtmp files.

SEE ALSO

w(1), users(1), last(1), whoami(1), finger(1)

Copied to clipboard