James Rayner <[EMAIL PROTECTED]>:
>Thanks! never knew pumount ever existed.
>
>Rafal: You should take a look at dbus + hal + ivman again, its isnt at
>all complicated. Just put dbus, hal and ivman in your DAEMONS line,
>and then just take the .default off the config files names in
>/etc/ivman.
Thanks. I know how to configure it but why would I want to use 3 things
when I can use only one (udev)? Submount is still on one of my machines
just because I was too lazy to write scripts for udev :-) (BTW thanks for
the idea with pmount I'll try it).
Maintaining 1 thing only is much easier especially after upgrades.
However this can change if I buy more removable devices. For
now I don't even have any usbsticks.
>You probably should stop using submount as last time I checked it isnt
>being developed any more. Ditto for supermount.
It's not being developed but it still works. I liked it so far for simplicity
and stability (yes, I know it's a bad bad design but for the desktop machine
it did its job).
>> On Sat, 2005-09-17 at 23:44 +1000, James Rayner wrote:
>> > if [ $ACTION == "remove" ]; then
>> > umount $DEVNAME
>>
>> Shouldn\'t you be using pumount for that?
>>
>> > else
>> > pmount $DEVNAME
>> > fi
>>
I think you should use full pathnames in your scripts. I had a problem
using chmod in my custom udev rules. Using /bin/chmod fixed it.
Also ACTION can be used inside the rule. For example:
ACTION=="add", BUS=="usb", KERNEL=="sd*", NAME="%k", GROUP="users",
RUN+="/usr/bin/pmount -w $env{DEVICE}"
ACTION=="remove", BUS=="usb", KERNEL=="sd*", NAME="%k", GROUP="users",
RUN+="/usr/bin/pumount $env{DEVICE}", OPTIONS="last_rule"
This is only a simple example. You can extend it for a special device only
using SYSFS field. Latest udev versions allow you to do things in several
ways.
BTW Don't forget about new udev syntax ("==", "+=", etc. ) and rules
processing. If you want to add your custom rules I'd suggest creating a file:
/etc/udev/rules.d/010.udev.rules
and adding to the last rule for a given device OPTIONS="last_rule"
which will ensure no other rule from the standard file will overwrite
it later.
Pmount has some options and policy too. For example a device can't
be listed in /etc/fstab - check pmount man page for details.
_______________________________________________
arch mailing list
[email protected]
http://www.archlinux.org/mailman/listinfo/arch