Home Linux Commands How to Get Information About Other Linux Users

How to Get Information About Other Linux Users

On your personal computer at home, you are most likely the only user who is connected to your Linux system. However, if you are a user at the Linux server in your company there can be other users as well.

In this case, it is good practice to know the information about other users who are currently connected to the same Linux machine using several commands.

How to Check Currently Logged in Users in Linux

To begin, use the users’ command – which shows a list of all users currently connected to the Linux system with no further details:

# users
Check Logged in Linux Users
Check Logged in Linux Users

If you want to know more information about the currently logged-in users, you need to use the who command as explained in the next section.

How to Get Information of Currently Logged in Users in Linux

The who command not only prints the users who are currently connected to the system, but also the IP address from where they are logged in and at what time.

# who
Get Information Of Currently Logged in Users
Get Information Of Currently Logged in Users

The reality that who command prints the IP address of remote users is extremely helpful. If, for example, a user is misbehaving then the system administrator knows from which IP address that user is connected, and this makes it easier to take corrective actions and lock the user permanently from the system.

How to Check Users Activity in Linux

If you want to know what a user is doing on the system, you need to use the w command – which shows you the names of users, from where they are logged in, and at what time, ongoing usage statistics, and what commands or programs they currently are running.

$ w
Check User Activity in Linux
Check User Activity in Linux

If you want to know more information about other users, try using the finger command as explained.

Find More Information of Users in Linux

The finger command shows a summary of the current state of a local user account that includes user recent activity, unread mail messages, and home directory. In most of the Linux distributions, the finger command isn’t installed by default.

$ sudo apt-get install finger  [On Debian/Ubuntu & Mint]
$ sudo dnf install finger      [On RHEL/Fedora/CentOS/Rocky Linux and AlmaLinux]

Once installed, you can run the finger command followed by the username as shown.

# finger linuxshelltips
Find User Information in Linux
Find User Information in Linux

In this short article, I’ve shown several commands to get the user information in Linux. If you know any other command to get the user details, do share with us in the comments.

Ravi Saive
I am an Experienced GNU/Linux expert and a full-stack software developer with over a decade in the field of Linux and Open Source technologies. Founder of TecMint.com, LinuxShellTips.com, and Fossmint.com. Over 150+ million people visited my websites.

Each tutorial at UbuntuMint is created by a team of experienced writers so that it meets our high-quality standards.

Was this article helpful? Please add a comment to show your appreciation and support.

1 thought on “How to Get Information About Other Linux Users”

  1. “If you are a user at the Linux server in your company”

    Mere users do not get access to login shells on corporate servers.

    Reply

Got something to say? Join the discussion.

Thanks for choosing to leave a comment. Please keep in mind that all comments are moderated according to our comment policy, and your email address will NOT be published or shared. Please Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.