Question regarding tty.

Question regarding tty.

Post by Usman Muzaff » Wed, 05 Oct 1994 05:18:14



Hello; I hope this question isn't too vague, but what exactly does tty
mean and what is ttys0 or ttyp2 or whatever? I know "tty" is a leftover
term from days of teletype machines, but what are UNIX systems referring
to when they say user johndoe on machine.domain ttyxx? Is it just an
arbitrary number used to keep track of how many terminals are connected?
Or does it have some meaningful use?

Second... this happens to me all the time... I'll log into my unix host
remotely; and then for some reason or the other, the connection is lost
before I can log out (say, my mac crashes or whatever.) Then I login
again, and finger myself - and the machine says that I'm on twice, once
from each of the two tty's I logged in from. Is there anyway I can access
that "hidden" shell? It logs out by itself once its been idle for the set
time, but can I somehow "kill" it without leaving it on?

any help/comments would be greatly appreciated.

thanks,
usman

 
 
 

Question regarding tty.

Post by Usman Muzaff » Wed, 05 Oct 1994 05:25:21


Hello; I hope this question isn't too vague, but what exactly does tty
mean and what is ttys0 or ttyp2 or whatever? I know "tty" is a leftover
term from days of teletype machines, but what are UNIX systems referring
to when they say user johndoe on machine.domain ttyxx? Is it just an
arbitrary number used to keep track of how many terminals are connected?
Or does it have some meaningful use?

Second... this happens to me all the time... I'll log into my unix host
remotely; and then for some reason or the other, the connection is lost
before I can log out (say, my mac crashes or whatever.) Then I login
again, and finger myself - and the machine says that I'm on twice, once
from each of the two tty's I logged in from. Is there anyway I can access
that "hidden" shell? It logs out by itself once its been idle for the set
time, but can I somehow "kill" it without leaving it on?

any help/comments would be greatly appreciated.

thanks,
usman

 
 
 

Question regarding tty.

Post by John Navar » Wed, 05 Oct 1994 11:36:41




>from each of the two tty's I logged in from. Is there anyway I can access
>that "hidden" shell? It logs out by itself once its been idle for the set
>time, but can I somehow "kill" it without leaving it on?

I will give an alternative answer to phil's response on this one. Instead
of dealing with the problem AFTER it happens, there is a nice way to take
a measure BEFORE it occurs. Now, the administrators of evilcasbah are not
going to like this but if they had installed the screen program, then I
wouldn't have to refer you to my copy. I get the feeling that you are
pretty new to Unix so perhaps this is not the best time for you to learn
about it, however, keep it in mind.

With screen, you never really "logout" per se. You use real homegrown
pseudoterminals (ptys, not ttyps) and you simply "detach" your session.
The nice thing about this is that if your computer blew up, some idiot
cut your telephone line down, or whatever tragedy struck, there is a
buffer between you and the controlling terminal (called screen) which
doesn't really care unless explicitely told to detach. Thus, you can
just log back in and resume your session under a different controlling
terminal and continue. I should point out in some ugly situations, it
is not always so easy as this but it is always possible to tell screen
to re-attach me  somewhere else (as if to say, "Hey you stupid
terminal over there, you suck, I am taking my business elsewhere.")

And of course you can have multiple screens!

-tms

--
You can get further with a kind word | You can get further with a kind word
and a gun than a kind word alone.    | and a phaser than a kind word and a gun.
          --al capone                |           -- John Navarra

 
 
 

Question regarding tty.

Post by Bill Marc » Thu, 06 Oct 1994 08:27:47


This may vary from system to system, but the ttyxx numbers usually refer
to actual serial ports or modems.  So if you have trouble with line noise
or loss of connections, you can make a note of the tty number and report
it to the management.  I'm not sure if this applies to telnet connections.

As for your second question, you can give the command
ps -u yourname
to get the numbers of all processes logged in under your name, and then
you can kill them.

--

Disclaimer:  Opinions expressed are bla bla bla, yackety smackety.

 
 
 

Question regarding tty.

Post by muzaf.. » Tue, 04 Oct 1994 15:18:14


Organization: Northwestern University, Evanston, IL  USA

Hello; I hope this question isn't too vague, but what exactly does tty
mean and what is ttys0 or ttyp2 or whatever? I know "tty" is a leftover
term from days of teletype machines, but what are UNIX systems referring
to when they say user johndoe on machine.domain ttyxx? Is it just an
arbitrary number used to keep track of how many terminals are connected?
Or does it have some meaningful use?

Second... this happens to me all the time... I'll log into my unix host
remotely; and then for some reason or the other, the connection is lost
before I can log out (say, my mac crashes or whatever.) Then I login
again, and finger myself - and the machine says that I'm on twice, once
from each of the two tty's I logged in from. Is there anyway I can access
that "hidden" shell? It logs out by itself once its been idle for the set
time, but can I somehow "kill" it without leaving it on?

any help/comments would be greatly appreciated.

thanks,
usman


 
 
 

Question regarding tty.

Post by B.A.McCau.. » Wed, 12 Oct 1994 20:32:51



Quote:>Hello; I hope this question isn't too vague, but what exactly does tty
>mean and what is ttys0 or ttyp2 or whatever? I know "tty" is a leftover
>term from days of teletype machines, but what are UNIX systems referring
>to when they say user johndoe on machine.domain ttyxx? Is it just an
>arbitrary number used to keep track of how many terminals are connected?
>Or does it have some meaningful use?

It's fairly arbitary. ttys* usually refer to specific serial ports on
the box but ttyp* devices are just allocted to network logins from a pool.

Quote:>Second... this happens to me all the time... I'll log into my unix host
>remotely; and then for some reason or the other, the connection is lost
>before I can log out (say, my mac crashes or whatever.) Then I login
>again, and finger myself - and the machine says that I'm on twice, once
>from each of the two tty's I logged in from. Is there anyway I can access
>that "hidden" shell? It logs out by itself once its been idle for the set
>time, but can I somehow "kill" it without leaving it on?

You can kill it with the kill command.
--

 .  _\\__[oo       from       | Phones: +44 121 471 3789 (home)

.  l___\\    /~~) /~~[  /   [ | PGP-fp: D7 03 2A 4B D8 3A 05 37
 # ll  l\\  ~~~~ ~   ~ ~    ~ |         A1 93 FE EA BE E3 2A 91

 
 
 

1. How to map a tty port to another tty port

Hi,

I just installed a new Linux system where users will connect to it using
telnet. On this server I installer a Digi port server (16 ports RS-232).
These 16 ports are connected to another Unix system that is maintained by
another company. I have no access whatsover to administrate this system. I
would like to have my users to connect directly through a telnet session to
one of the ports on my port server. For example how can I redirect input and
output from /dev/pts/2 to /dev/ttyd0.

Thanks for your time
--
/*
 *
 * Infocom enr.
 * Jean-Pierre Dub
 *
 */

2. Imagemaps

3. creating tty's, mknod, stuck after boot with wrong tty - help

4. Fwd: Re: NDA used for drivers/usb/storage/shuttle_usbat.c?

5. problems with tty, U469036 - bos.rte.tty.4.3.2.9

6. Linux vs Win2KAdvSvr vs Samba

7. - can one change tty modes for tty not stdio ?

8. kernel install?

9. tty, tty... where art thou ...?

10. tty problem: only root and non-X get tty!

11. Good book on tty, pseudo tty, termio etc ?

12. new tty/old tty

13. Is is possible to make remote tty look like local tty