Subject: Re: FreeBSD 5/6/7 kernel emulator for NetBSD 2.x
To: None <firstname.lastname@example.org>
From: John Baldwin <email@example.com>
Date: 10/31/2005 11:54:32
On Saturday 29 October 2005 06:59 am, Rui Paulo wrote:
> On 2005.10.29 00:01:42 -0600, M. Warner Losh wrote:
> | In message: <20051026181403.GF1702@neuron.fnop.net>
> | Rui Paulo <firstname.lastname@example.org> writes:
> | : On 2005.10.26 10:22:52 -0700, Bill Studenmund wrote:
> | : | On Mon, Oct 24, 2005 at 10:35:47PM +0200, Hans Petter Selasky wrote:
> | : | > Main features:
> | : | >
> | : | > - Implements FreeBSD's devfs on NetBSD.
> | : |
> | : | In the past, we (NetBSD folks) have talked about a devfs. One issue
> | : | that has come up (I'll be honest, I've raised it a lot) is a desire
> | : | to retain permission changes across boots, and to tie devices (when
> | : | possible) to a device-specific attribute rather than a probe order.
> | : |
> | : | Does FreeBSD's devfs support locators and persistent information? Are
> | : | there plans to support something like that, if not?
> | :
> | : I remember Linux's devfs having a configure file for that particular
> | : objective. The user would set the permission flags in (I can't recall
> | : if this is the real name) /etc/devfsd.conf and let devfsd do the job.
> | :
> | : You could also use another directory for permissions, like /dev-state,
> | : but personally, I don't like this method.
> | :
> | : http://www.atnf.csiro.au/people/rgooch/linux/docs/devfs.html#persistenc
> | :e
> | FreeBSD also has a file that can be used to control the permissions
> | and ownerships at runtime. The persistance can be there, but isn't
> | there by default like the old nodes in /dev.
> The other problem I see here is how devfs works in single user mode
> where devfsd is not started and no permissions are set. How does
> FreeBSD solve this problem?
Well, for one thing you generally are root in single user mode such that
permissions on /dev aren't quite as important as multi-user. :) However, the
devfs rulesets are managed in the kernel, and there isn't a userland devfsd,
so you could always manually set or load the devfs rules you want to apply
while you are in single user. I think the biggest thing to think about is
that devfs makes you think about /dev differently. It's more of a true
psuedo-filesystem where there aren't actual files representing devices like
the special device nodes that mapped to specfs. It's more like procfs. Do
you ty to solve the problem of persistent permissions for files in /proc?
John Baldwin <jhb@FreeBSD.org> <>< http://www.FreeBSD.org/~jhb/
"Power Users Use the Power to Serve" = http://www.FreeBSD.org