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

Udev rule for external hard-drive



Hello all,

I'm attempting a rule for my new external hard-drive, but it doesn't
seem to be taking. For reference, I am using Debian 5.0.5 am following
the wiki's instructions[1] and am using the kernel developers' guide
as a reference[2]. My udevinfo output:

> $ udevinfo -a -p /sys/block/sdb/sdb1/ | grep serial
>    ATTRS{serial}=="57442D575839314133303236343538"
>    ATTRS{serial}=="0000:00:1a.7"

And the custom rule file 10-local.rules:

> SUBSYSTEM=="block", SUBSYSTEMS=="scsi", ATTRS{serial}=="57442D575839314133303236343538", SYMLINK+="external%n"

After restarting Udev I'm greeted with the following dmesg output:

> [138065.272612] scsi10 : SCSI emulation for USB Mass Storage devices
> [138065.272965] usb 3-3: New USB device found, idVendor=1058, idProduct=1010
> [138065.272972] usb 3-3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
> [138065.272978] usb 3-3: Product: External HDD
> [138065.272983] usb 3-3: Manufacturer: Western Digital
> [138065.272988] usb 3-3: SerialNumber: 57442D575839314133303236343538
> [138065.273008] usb-storage: device found at 9
> [138065.273012] usb-storage: waiting for device to settle before scanning
> [138070.327947] usb-storage: device scan complete
> [138070.328938] scsi 10:0:0:0: Direct-Access     WD       1200BEV External 1.75 PQ: 0 ANSI: 4
> [138070.334995] sd 10:0:0:0: [sdb] 234441648 512-byte hardware sectors (120034 MB)
> [138070.336676] sd 10:0:0:0: [sdb] Write Protect is off
> [138070.336676] sd 10:0:0:0: [sdb] Mode Sense: 23 00 00 00
> [138070.336676] sd 10:0:0:0: [sdb] Assuming drive cache: write through
> [138070.337550] sd 10:0:0:0: [sdb] 234441648 512-byte hardware sectors (120034 MB)
> [138070.338045] sd 10:0:0:0: [sdb] Write Protect is off
> [138070.338045] sd 10:0:0:0: [sdb] Mode Sense: 23 00 00 00
> [138070.338045] sd 10:0:0:0: [sdb] Assuming drive cache: write through
> [138070.338045]  sdb: sdb1
> [138070.376812] sd 10:0:0:0: [sdb] Attached SCSI disk

Clearly I'm doing something wrong. Can someone point me in the right direction?

Thanks,
Brian

---
[1] http://wiki.debian.org/AutoFs
[2] http://www.reactivated.net/writing_udev_rules.html#udevinfo


Reply to: