1

I use VirtualBox for Ubuntu on my Windows 7 computer. I set up SSH and got in through Putty just fine. However I wanted to know how to see who was connected. So I Googled a bit and found "who" and tried it.

myname@ubuntuComputer:~$ who
myname :0           2014-07-02 17:55 (:0)
myname pts/0        2014-07-02 17:58 (:0)
myname pts/4        2014-07-02 19:49 (nameOfHomeComputer.home)

Can anyone explain to me what these figures all mean? Why are there three? What are the 0's and pts/0 pts/4 thing?

Radu Rădeanu
  • 174,089
  • 51
  • 332
  • 407
user51819
  • 283

1 Answers1

1

The who command, as you've already figured out, outputs user information. If I type in who in my Terminal right now I get the following:

viktor   :0           2014-07-02 15:41 (:0)
viktor   pts/0        2014-07-03 02:07 (:0)

Now, in both these cases I'm logged in as viktor. The first one is my default desktop, Ubuntu itself, the current logged in user in the system. I started my computer 15.41 yesterday. The second row belong to the Terminal I launched to execute the who command. The terminal will login as your user once more since the Terminal really is a desktop environment, or shell, as well (Bash).

As for the 0's and the second column I'd like to refer to another question where the answer is very well explaining.

As for your own example the following is your result:

You have one user logged in as the system started that is running all the time, your first row. The second is the terminal you used to execute the command, I guess? And the third is your SSH connection, who logged in as the user you specified.

You can see that if you open many terminals your list will grow, as for more SSH connections. I hope this have been helpful.

Xweque
  • 1,103