View Full Version : make usb persistently mount at sdb and sdc?

10-18-2007, 10:47 PM
Using knoppix 5.1.1. dvd "frugal" install.

Is there a way to made a device mount at specific device point without using fstab?

i.e. in ubuntu, create/modify /etc/udev/rules.d/10-local.rules and include serial numbers picked up by doing
udevinfo -a -p $(udevinfo -q path -n /dev/sdb)
and appending the serial numbers like:
# ipod sdb1 and 2
BUS=="usb", ATTRS{serial}=="000A2700126D3316", NAME{all_partitions}=="temp"
# sandisk cruzer mini sdc1
BUS=="usb", ATTRS{serial}=="SNDK8CDE840C8EE08501", NAME{all_partitions}=="temp"

I unplugged the devices, then I restarted udev using

sudo /etc/init.d/udev restart
I get
Stopping the hotplug events dispatcher: udevd.
Starting the hotplug events dispatcher: udevd.

So that went well, but if I plug in the cruzer then the ipod, then it doesn't "take" and the cruzer is sdb1
sudo udevtest /sys/block/sdc block
I get
unable to open device 'block'

I know Knoppix is different that ubuntu, but I figured there would be similarity, being debian based.

In my ubuntu hack, it the whole precess uses SYSFS instead of ATTRS, but the udevinfo -a -p used ATTRS instead of SYSFS.