Go Job Hunting at the LQ Job Marketplace
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


Search this Thread
Old 02-20-2013, 09:50 PM   #1
Registered: Aug 2011
Posts: 754

Rep: Reputation: 23
who/what is this on 'who' command output

The output of 'who' command on my debian sid system with lxde and lightdm is:
$ who
abcde tty7 2013-02-21 08:37
abcde pts/0 2013-02-21 08:37 (:0)
abcde pts/1 2013-02-21 08:37 (:0)
I have two terminals open at this time. My username is abcde. If I remember correctly, 'who' used to give 2 lines pts/0 and pts/1 when 2 terminals were open. What is this tty7 entry?

I tried command 'ps aux | grep tty7' . The output was:
$ ps aux | grep tty7
root 902 3.0 2.4 25844 12448 tty7 Ss+ 08:37 1:16 /usr/bin/Xorg :0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch
Is there anything to worry about here? Thanks for your help.
Old 02-20-2013, 11:11 PM   #2
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.6, Centos 5.10
Posts: 16,401

Rep: Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081
The tty session is where you logged in, pts is for the 2 terminals you have open.
Old 02-21-2013, 03:19 AM   #3
Senior Member
Registered: Sep 2012
Location: Italy
Distribution: Slackware, NetBSD
Posts: 1,382
Blog Entries: 5

Rep: Reputation: 271Reputation: 271Reputation: 271
This thread could be useful
1 members found this post helpful.
Old 02-21-2013, 07:10 AM   #4
Senior Member
Registered: Jan 2011
Distribution: Undecided
Posts: 3,859
Blog Entries: 1

Rep: Reputation: Disabled
Originally Posted by rng View Post
What is this tty7 entry?
It is your login to the desktop that is using this.

Close programs and logout to login screen.
Ctrl+Alt+F1 but do not login
Ctrl+Alt+F7 should take you back to graphical login dialog.

Nothing to worry about.

tty7 will always be in use if you are using a desktop environment. The other 2 are your 2 open bash shells.
Old 02-21-2013, 07:47 AM   #5
Registered: Aug 2011
Posts: 754

Original Poster
Rep: Reputation: 23
Thanks for your reassuring comments.

I have debian wheezy (with lxde- same as the one with debian sid/unstable) installed on another computer where 'who' command outputs only pts/1 and pts/0 lines. No tty line here.

Though the command 'ps aux | grep tty' produces this output:
root 1096 0.0 0.0 3780 848 tty1 Ss+ 20:24 0:00 /sbin/agetty tty1 38400
root 1107 0.5 0.9 58520 36996 tty7 Ss+ 20:24 0:36 /usr/bin/X :0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch
How do you explain that?

Last edited by rng; 02-21-2013 at 10:42 AM.
Old 02-21-2013, 10:51 AM   #6
Senior Member
Registered: Jan 2011
Distribution: Undecided
Posts: 3,859
Blog Entries: 1

Rep: Reputation: Disabled
I don't run debian, so I can't explain it with any reasonable assurance.

Different implementation of the "who" command, an alias that suppresses tty on "who"?, I could theorize for an hour on any one of of those 'reasons', but I'd be talking out of my arse.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Requests to my ISP server are output in the middle of output by any command I run. stf92 Slackware 2 07-10-2012 08:38 AM
How to redirect the output of exec command output in perl? sudhap85 Linux - Newbie 3 08-28-2009 03:35 PM
[SOLVED] append command output to file by giving command in terminal sumeet inani Linux - Newbie 4 07-03-2009 10:36 AM
Grep on output of command returns all output traigo Linux - Newbie 2 02-24-2009 05:15 PM
How do I parse the output of a command that output to standard out? gauol Programming 9 01-17-2008 01:54 PM

All times are GMT -5. The time now is 05:09 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration