tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Setting TERM in single user mode



On Tue, 7 Oct 2008, Geoff Wing wrote:

On Monday 2008-10-06 12:14 -0400, Greg A. Woods; Planix, Inc. output:
Strictly speaking "console" should be _removed_ from /etc/ttys.  It is
(now) always the wrong device to run getty on.  A "constty" entry is the
only correct way to properly access the system console TTY device.

It still has meaning for single user mode.  See init(8):

   If the `console' entry in the ttys(5) file is marked ``insecure'', then
   init will require that the superuser password be entered before the sys-
   tem will start a single-user shell.  The password check is skipped if the
   `console' is marked as ``secure''.

So you can have something like this in /etc/ttys :

   console "/usr/libexec/getty Pc"         vt100   off insecure
   ttyE0   "/usr/libexec/getty Pc"         vt220   on secure


        This is actually a very good reason for console *and* constty:

            console "/usr/libexec/getty Pc"         vt220   off
            constty "/usr/libexec/getty Pc"         vt220   on secure
            ttyE0   "/usr/libexec/getty Pc"         vt220   off secure

        The above will also DTRT with a serial console


--
                David/absolute       -- www.NetBSD.org: No hype required --


Home | Main Index | Thread Index | Old Index