w Linux Command
Displays who is logged in and what they are currently doing.
What does w do?
Displays who is logged in and what they are currently doing.
Syntax
w [username]Practical example
wRelated User Management
whoShows all users currently logged into the system with login details.
idPrints user and group IDs (UID, GID) for the specified or current user.
whoamiDisplays the username of the currently logged-in user.
suSwitches to another user account or the root user.
lastShows the last logged-in users from the system log file.
sudoExecutes a command with superuser (root) privileges.