I have two separate controllers, SATA and PATA.
I would like to rename drives connected to the PATA to hd[a-z], and their partitions to hd[a-z][0-9].# udevadm info -a -p /sys/block/sdd [...] looking at device '[...]/target8:0:1/8:0:1:0/block/sdd': KERNEL=="sdd" SUBSYSTEM=="block" [...] looking at parent device '[...]/target8:0:1': KERNELS=="target8:0:1" SUBSYSTEMS=="scsi" [...] looking at parent device '[...]': KERNELS=="0000:02:00.1" SUBSYSTEMS=="pci" DRIVERS=="pata_jmicron"
Knowing that i tried to write new rule in /etc/udev/rules.d/59-drives.rules:
DRIVERS=="pata_jmicron", SUBSYSTEM=="block", KERNELS=="target8:0:0", NAME="hda" DRIVERS=="pata_jmicron", SUBSYSTEM=="block", KERNELS=="target8:0:1", NAME="hdb"
No luck though. What am I missing?
PS. Persistent block device naming? No, thank you.
Answer
Turns out kernel devices cannot be renamed:
udevd[648]: NAME="hdb" ignored, kernel device nodes can not be renamed; please fix it in /etc/udev/rules.d/59-drives.rules:2
Attribution
Source : Link , Question Author : udev , Answer Author : udev