Re: [gentoo-user] program to view/control virtual terminals (ctrl-alt-f[1-6])

2006-06-29 Thread Etaoin Shrdlu
On Thursday 29 June 2006 03:15, Iain Buchanan wrote:

 Can anyone think of more suggestions?  I'm trying to use these
 consoles as if I was sitting at the machine, but really I'll be
 ssh-ing in from somewhere.  I could even write something in c if
 necessary, but my attempts so far don't catch output or send input
 properly...

 I'd appreciate any suggestions.

Google for ttysnoop.
HTH
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] program to view/control virtual terminals (ctrl-alt-f[1-6])

2006-06-28 Thread Richard Fish

On 6/28/06, Iain Buchanan [EMAIL PROTECTED] wrote:

The suggestions were screen, and showconsole.  showconsole only shows
output, and doesn't let you type into it; and screen can't (?) attach to
such a virtual console.


Screen can definitely attach to a virtual console.  I just tried the
following in /etc/inittab:

c5:2345:respawn:/usr/bin/screen -R tty5.localhost /bin/login

/dev/tty5 /dev/tty5 21

c6:2345:respawn:/usr/bin/screen -R tty6.localhost /bin/login

/dev/tty6 /dev/tty6 21


You can then attach to either of those with

screen -D -r tty5.localhost
screen -D -r tty6.localhost

The only thing you really can't do is login as root, because screen
uses psuedo tty's which are declared unsecure by default.  Unless you
want to add all pty devices to /etc/securetty...

But there is no security with this setup anyway, because on a console
all one has to do is Ctrl-a c to get a root shell.

Still, this should give you an idea of what you will have to do if you
are going to write your own program to manage this...

-Richard
--
gentoo-user@gentoo.org mailing list