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

HowTo limit automounting hotpluggable devices for certain group of users?

0 views
Skip to first unread message

kaedekai

unread,
Dec 2, 2009, 12:12:19 AM12/2/09
to
Hi all,

I am new to linux. I was wondering how we can control automounting
for hotpluggable device for certain user group.

The problem I had is as follows:

I have 2 user groups: admin & user

I would like to only allow users in the "admin" group to auto mount/
unmount devices.
For example, when user in the "admin" group insert a usb device, it
will automount the device.

However, if users in the "user' group plug in a usb device, it will
not perform any mounting/unmounting.

I have try using sudoers to control the mount/umount. However, no
matter what I did, the device will get mount automatcially as soon as
a device get inserted regardless of the group.


Thanks in advance for any help.

Kaedekai

Jan Gerrit Kootstra

unread,
Dec 2, 2009, 1:27:46 AM12/2/09
to
kaedekai schreef:
Kaedekai,


Hotplug of a device is not done by an user, it is done by a process run
under root.

So if you do not want automatically mount of an usb device this process
has to be stopped.

I am sorry that I forgot the name of 'daemon'


Kind regards,


Jan Gerrit Kootstra

Eef Hartman

unread,
Dec 8, 2009, 8:41:27 AM12/8/09
to
Jan Gerrit Kootstra <jan.g...@kootstra.org.uk> wrote:
> Hotplug of a device is not done by an user, it is done by a process run
> under root.
>
> So if you do not want automatically mount of an usb device this process
> has to be stopped.
>
> I am sorry that I forgot the name of 'daemon'

udev/hald
(udev will create the device files, hald does the actual mounting).

I _think_ you can go a long way by specying the devices for the
auto-mount to be "group admin" with no read/write access for the
world, that CAN be done through udev rules files.
I think by default sd? devices special files are created in the
"disk" group and there is (in other distro's, don't know about
red Hat) a "plugindev" group to which the user must belong TO
get the automount.
--
*******************************************************************
** Eef Hartman, Delft University of Technology, dept. SSC/ICT **
** e-mail: E.J.M....@tudelft.nl - phone: +31-15-278 82525 **
*******************************************************************

0 new messages