Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

How to restart devfs

1,347 views
Skip to first unread message

Nicola Mingotti

unread,
Aug 21, 2006, 10:27:18 PM8/21/06
to
Hi,

Is there a way to restart "DEVFS" ?
The question raised when changing "/etc/devfs.rules"
i wanted to test without reboot.

Thank you in advance
Regards
Nicola Mingotti

Tim Judd

unread,
Aug 21, 2006, 10:52:34 PM8/21/06
to

isn't there a process called devfs? (maybe devfsd)

sighup it. failing that, reboot. rebooting is not a taboo act,
sometimes it's just needed.

g'luck.

Nicola Mingotti

unread,
Aug 21, 2006, 11:29:20 PM8/21/06
to
Tim Judd wrote:
> Nicola Mingotti wrote:
>> Hi,
>>
>> Is there a way to restart "DEVFS" ?
>> The question raised when changing "/etc/devfs.rules"
>> i wanted to test without reboot.
>>

> isn't there a process called devfs? (maybe devfsd)
No, there isn't :
-------
$> ps auxww | grep -i dev
root 259 0.0 0.1 1260 768 ?? Is 4:10AM 0:04.32
/usr/sbin/moused -p /dev/ums0 -t auto -I /var/run/moused.ums0.pid
root 296 0.0 0.1 500 360 ?? Is 4:10AM 0:00.00 /sbin/devd
p 946 0.0 0.2 1512 984 p3 S+ 5:24AM 0:00.00 grep -i dev
-------

> sighup it. failing that, reboot. rebooting is not a taboo act,
> sometimes it's just needed.

I thought the same thing, but when i didn't find the process I choose to
ask ;-)

Thank you anyway

Message has been deleted

Pet Farrari

unread,
Aug 22, 2006, 4:03:27 AM8/22/06
to
Patrick Lamaizière wrote:
> Nicola Mingotti :

>
>> Is there a way to restart "DEVFS" ?
>> The question raised when changing "/etc/devfs.rules"
>
> "/etc/rc.d/devfs restart"
>
I wonder if devfs restart will corrupt the current file system mount
points. Currently I have the following devfs file systems mounted, but 3
of the devfs mount poitns are redundant. I want to reset devfs so that I
can remove the redundant devfs mount points.
Please see below for the devfs mounted filesystems:


/dev/ar0s1g 80043880 2976744 70663626 4% /usr
/dev/ar0s1d 5077038 181840 4489036 4% /var
/dev/da0s1 2113438652 435941530 1656362736 21% /fat0
/dev/da1s1 547669366 303182904 239009770 56% /fat1
devfs 1 1 0 100%
/fat0/jails/intranet.anatas.com/dev
devfs 1 1 0 100%
/fat0/jails/intranet.anatas.com/dev
devfs 1 1 0 100%
/fat0/jails/intranet.anatas.com/dev
devfs 1 1 0 100%
/fat0/jails/intranet.anatas.com/dev
procfs 4 4 0 100%
/fat0/jails/intranet.anatas.com/proc
devfs 1 1 0 100% /var/named/dev

Michel Talon

unread,
Aug 22, 2006, 5:58:37 AM8/22/06
to

The file /etc/devfs.conf (there is no devfs.rules in my machine) is
read at startup by the script /etc/rc.d/devfs. So you have only to
/etc/rc.d/devfs restart
If you read the script you will discover it is a very simple mechanism
to use chown and chmod on the devices following the information in devfs.conf.

Now there is a new mechanism, devd which is a daemon configured by devd.conf
which can do the same things and much more as soon as a kernel event is
discovered, such as adding an USB dongle. This can in principle supersede
all previous mechanisms such as devfs.conf and usbd, but has not been
imposed as the only mechanism presumably to apply the POLA principle.

--

Michel TALON

Michel Talon

unread,
Aug 22, 2006, 6:06:41 AM8/22/06
to
Pet Farrari <p...@auth.net.au> wrote:

> Patrick Lamaizičre wrote:
> > Nicola Mingotti :
> >
> >> Is there a way to restart "DEVFS" ?
> >> The question raised when changing "/etc/devfs.rules"
> >
> > "/etc/rc.d/devfs restart"
> >
> I wonder if devfs restart will corrupt the current file system mount
> points. Currently I have the following devfs file systems mounted, but 3

No, it just does chown and chmod on device entries. By the way device entries
can always be "created" on demand anywhere by the like of:
mkdir mydev
mount -t devfs devfs mydev
as root of course. You can also customize what appears in mydev, in particular
hide nodes by running the devfs hide command. You have an example of that
in the script /etc/rc.d/named, which creates a "/dev" in /var/named/dev, and
then hides all nodes except /dev/null and /dev/random, by using e.g.:
devfs -m ${named_chrootdir}/dev rule apply path null unhide


--

Michel TALON

0 new messages