How to tell who is logged into your VPS or Dedicated server

As a VPS or Dedicated Server account owner, you may want to check to see who is actively online and send a broadcast message to them. The short article below takes you through using the who and wall commands. Neither command requires root access.

How to see who is logged in

  1. Log into your account via SSH
  2. Run the who command from the command prompt. This will list anyone who is currently logged in.
    # who

    You should receive some output similar to the sample below. As you can see, the users root and bradm are logged in.

    root     pts/2        2013-01-25 12:53
    bradm    pts/3        2013-01-25 12:58

How to send a message to online users

Once you know who is logged into your server, you can send a message to them by using the wall command.
# wall
   This is a message
   <ctrl-d>
The users, including the sender, will see the message like the below sample.
Broadcast message from root (pts/2) (Fri Jan 25 12:52:25 2013):
This is a message

One thought on “How to tell who is logged into your VPS or Dedicated server

Was this article helpful? Join the conversation!