From owner-freebsd-current Thu Mar 21 08:20:31 1996 Return-Path: owner-current Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id IAA16709 for current-outgoing; Thu, 21 Mar 1996 08:20:31 -0800 (PST) Received: from GndRsh.aac.dev.com (GndRsh.aac.dev.com [198.145.92.241]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id IAA16685 for ; Thu, 21 Mar 1996 08:20:26 -0800 (PST) Received: (from rgrimes@localhost) by GndRsh.aac.dev.com (8.6.12/8.6.12) id IAA23813; Thu, 21 Mar 1996 08:16:42 -0800 From: "Rodney W. Grimes" Message-Id: <199603211616.IAA23813@GndRsh.aac.dev.com> Subject: Re: DEVFS vs "regular /dev" To: phk@critter.tfs.com (Poul-Henning Kamp) Date: Thu, 21 Mar 1996 08:16:42 -0800 (PST) Cc: davidg@Root.COM, terry@lambert.org, julian@ref.tfs.com, scrappy@ki.net, current@FreeBSD.org In-Reply-To: <678.827415254@critter.tfs.com> from "Poul-Henning Kamp" at Mar 21, 96 05:34:14 am X-Mailer: ELM [version 2.4 PL24] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-current@FreeBSD.org X-Loop: FreeBSD.org Precedence: bulk > > > >> >> >So you don't need a mounted root to have a mounted /dev, of course! > > >> >> > > >> >> That's silly. The root filesystem is mounted long before /dev would > be, > > > > > >> > > > >> >Not that long before. /sbin/init will have to mount it to get in touch > > >> >with /dev/console, /dev/null and ... > > > > I just re-read what you said...I think you might have read what I wrote > > backwards - the root filesystem is mounted automagically in the kernel very > > early in system startup. /dev, whether it's done in the kernel or in > > /sbin/init, would be done quite a bit later in relative terms. > well, yes, "later" in relative terms, but not many actual seconds though :-) > > > If we do the mount in /sbin/init and it fails for some reason (like the > > mount point doesn't exist), then we'll have no way to inform the operator > > (there isn't a /dev/console to write to). If we do it in the kernel, we can > > emit a message saying "/dev: not found" or something. > > I think sbin/init should be started with stdin+stdout pointing to console > for this and other reasons as well. Try this (ONLY MAKE SURE YOU HAVE A WAY TO RECOVER) if you wish to see the criticality of certain /dev/files: rm /dev/log rm /dev/klog rm /dev/console reboot Now spend a hour or two trying to find out why the damn system hangs right after mounting root. -- Rod Grimes rgrimes@gndrsh.aac.dev.com Accurate Automation Company Reliable computers for FreeBSD