Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 5 Aug 1997 17:59:41 +0400 (MSD)
From:      =?KOI8-R?B?4c7E0sXKIP7F0s7P1w==?= <ache@nagual.pp.ru>
To:        davidn@freebsd.org, FreeBSD-current <current@freebsd.org>
Subject:   init rc.shutdown code broken
Message-ID:  <Pine.BSF.3.96.970805175331.823A-100000@nagual.pp.ru>

next in thread | raw e-mail | index | archive | help
TIOCSCTTY _always_ fails in following runshutdown() fragment:

		if ((fd = open(_PATH_CONSOLE, O_RDWR)) == -1)
		    warning("can't open %s: %m", _PATH_CONSOLE);
		else {
		    if (ioctl(fd, TIOCSCTTY, (char *)NULL) == -1)
			warning("can't get %s for controlling terminal: %m", _PATH_CONSOLE);

To see this message just boot machine and then press CtrlAltDel
at login: prompt. You can add sleep 30 to rc.shutdown to not miss it.

So, console never be controlling terminal for shutdown process.
I think it is because console t_session is aleady set.
Don't have idea how to fix it, I try revoke() but it not helps.

-- 
Andrey A. Chernov
<ache@null.net>
http://www.nagual.pp.ru/~ache/




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.96.970805175331.823A-100000>