Subject: Re: Write back support of MAKEDEV in init
To: John Darrow <John.P.Darrow@wheaton.edu>
From: Julio Merino <firstname.lastname@example.org>
Date: 08/28/2002 14:59:32
Very interesting :) I'll try it later.
On Wed, 28 Aug 2002 07:48:24 -0500 (CDT)
John Darrow <John.P.Darrow@wheaton.edu> wrote:
> Julio Merino <email@example.com> wrote:
> >On Tue, 27 Aug 2002 20:29:17 +0200 (MEST)
> >Hubert Feyrer <firstname.lastname@example.org> wrote:
> >> On Tue, 27 Aug 2002, Julio Merino wrote:
> >> > > I wonder if mounting a mfs _over_ a pre-generated /dev would work?
> >> >
> >> > What do you mean?
> >> I thought of a on-disk /dev, with a mfs-based filesystem mounted (-t
> >> union) over it.
> >Hmm sounds interesting. How could this be made optional? For example,
> >use 'init -d union' to use an union or something... but this may require
> >a kernel option to indicate init flags?
> Why would init need to know about it at all? In fact, this can be done
> today with no code changes whatsoever. All it requires is:
> 1. An trimmed on-disk /dev, containing (e.g.) /dev/console and the disk
> devices necessary to boot, but not the things that need to be modified
> (e.g. permission changed) on the fly.
> 2. A suitably-trimmed MAKEDEV somewhere (doesn't have to be located in
> /dev) which can make the additional devices needed by (e.g.) sshd. If
> you're thinking you'll be wanting to change this at times, I'm sure you
> can find somewhere in your filesystem that is either always or at least
> can be made writable.
> 3. A hand-rolled rc.d script, put early enough in the boot process to
> run before any of the processes which need write access to /dev, that
> simply does:
> mount -t mfs -o union,-s=size swap /dev
> ( cd /dev && sh /wherever/you/put/it/MAKEDEV all-modifiable-devices )
> and, voila, modifiable /dev on a read-only root, without a seven minute
> wait every boot, and while still providing an way to keep the
> underlying MAKEDEV file around, unmodified, for reference. All this
> without touching a single byte of init code.
> John Darrow - Senior Technical Specialist Office: 630/752-5201
> Computing Services, Wheaton College, Wheaton, IL 60187 Fax: 630/752-5968
> Pager via email: email@example.com Pager: 630/316-0707
> Email: John.P.Darrow@wheaton.edu (plain text please, no HTML or proprietary)
HispaBSD admin - http://www.HispaBSD.org
For the developer - http://buildtool.sourceforge.net
Julio Merino <firstname.lastname@example.org>