Automount Volumes

Hi all,

just in case there's anyone out there who's using Sawfish standalone
but does not have automount support for removable storages, here a
pretty simple way:

install the pmount package (most distros already ship it, else
check )

create a file called /etc/udev/rules.d/automount.rules

with the rules for removable storages, here's my file, which should fit
the most of you, syntax should be clear, so modify it to your needs (if
it's not, just ask):

KERNEL=="sd*", ACTION=="add", RUN+="/usr/bin/pmount --sync --umask 000 %k"
KERNEL=="sd*", ACTION=="remove", RUN+="/usr/bin/pumount %k"

Now let the changes immediately take effect:

udevadm control --reload_rules 

Depending on the device it may take up to ~10 seconds before it's
mounted and also depending on the device up to another ~10 seconds
before you can access it via a file-manager, but most devices should be
accessible faster.

This way you don't need a plugdev group or to make pmount setuid-root
or something like that.

Mount points are /media/[node] (/dev/sdc2 is mounted to /media/sdc2)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]