Set perms on attach of USB umass disk

Darren Spruell phatbuckett at
Thu Nov 1 13:53:59 PDT 2007

> > I've tried altering devfs.conf but this appears to only work for
> > devices that are attached at startup of devfs.
> [snip]
> As a matter of fact, this is documented in the devfs.conf manual page.
> This will also tell you where to look;


"It does not work for devices plugged in and out after the system is up
and running, e.g. USB devices.  See devfs.rules(5) for setting ownership
and permissions for all device nodes, and usbd.conf(5) for actions to be
taken when USB devices are attached or detached."

I overlooked that for some reason. :(

> create a new file /etc/devfs.rules with contents
> [system=10]
> add path 'da*' mode 660 group operator
> Then in /etc/rc.conf add
> devfs_system_ruleset="system"
> and restart devfs (/etc/rc.d/devfs restart)

Works great, thanks.

Darren Spruell
phatbuckett at

More information about the freebsd-questions mailing list