udev device-persistence problem

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

 



FC6 - kernel 2.6.18-1.2798.fc6 - udev-095-14

I'm trying to develop some rules to give me device-name
persistence on my SCSI disks. I have a couple of test rules:

BUS=="scsi", PROGRAM="/sbin/scsi_id -g -u"
RESULT=="20004cffffe0e0976", NAME="dsk0_%n", OWNER="root", GROUP="root", MODE="0700"
RESULT=="SSEAGATE_ST336807LC_3KT0CTTM00007530YTR2", NAME="dsk1_%n", OWNER="root", GROUP="root", MODE="0700"

With these rules disabled, I get:

[root@dev1 ~]# ls -l /dev/dsk* /dev/sd* /dev/sg*
brwx------ 1 root disk  8,  0 Nov 28 11:48 /dev/sda
brwx------ 1 root disk  8,  1 Nov 28 11:48 /dev/sda1
brwx------ 1 root disk  8, 16 Nov 28 11:48 /dev/sdb
brwx------ 1 root disk  8, 17 Nov 28 11:48 /dev/sdb1
brwx------ 1 root disk  8, 18 Nov 28 11:48 /dev/sdb2
brwx------ 1 root disk  8, 19 Nov 28 11:48 /dev/sdb3
brwx------ 1 root disk  8, 20 Nov 28 11:48 /dev/sdb4
brwx------ 1 root disk  8, 21 Nov 28 11:48 /dev/sdb5
brwx------ 1 root disk  8, 22 Nov 28 11:48 /dev/sdb6
brwx------ 1 root disk  8, 23 Nov 28 11:48 /dev/sdb7
brwx------ 1 root disk  8, 24 Nov 28 11:48 /dev/sdb8
crw------- 1 root root 21,  0 Nov 28 11:48 /dev/sg0
crw------- 1 root root 21,  1 Nov 28 11:48 /dev/sg1

(Note the two sg generic entries).

If I now enable these rules and reboot, I get:

[root@dev1 ~]#  ls -l /dev/dsk* /dev/sd* /dev/sg*
brwx------ 1 root disk  8,  0 Nov 28 12:05 /dev/dsk0_
crw------- 1 root root 21,  0 Nov 28 12:05 /dev/dsk0_0
brwx------ 1 root disk  8,  1 Nov 28 12:05 /dev/dsk0_1
brwx------ 1 root disk  8, 16 Nov 28 12:05 /dev/dsk1_
brwx------ 1 root disk  8, 17 Nov 28 12:05 /dev/dsk1_1
brwx------ 1 root disk  8, 18 Nov 28 12:05 /dev/dsk1_2
brwx------ 1 root disk  8, 19 Nov 28 12:05 /dev/dsk1_3
brwx------ 1 root disk  8, 20 Nov 28 12:05 /dev/dsk1_4
brwx------ 1 root disk  8, 21 Nov 28 12:05 /dev/dsk1_5
brwx------ 1 root disk  8, 22 Nov 28 12:05 /dev/dsk1_6
brwx------ 1 root disk  8, 23 Nov 28 12:05 /dev/dsk1_7
brwx------ 1 root disk  8, 24 Nov 28 12:05 /dev/dsk1_8
brwx------ 1 root root  8,  0 Nov 28 12:04 /dev/sda
brwx------ 1 root root  8,  1 Nov 28 12:04 /dev/sda1
brwx------ 1 root root  8, 16 Nov 28 12:04 /dev/sdb
brwx------ 1 root root  8, 17 Nov 28 12:04 /dev/sdb1
brwx------ 1 root root  8, 18 Nov 28 12:04 /dev/sdb2
brwx------ 1 root root  8, 19 Nov 28 12:04 /dev/sdb3
brwx------ 1 root root  8, 20 Nov 28 12:04 /dev/sdb4
brwx------ 1 root root  8, 21 Nov 28 12:04 /dev/sdb5
brwx------ 1 root root  8, 22 Nov 28 12:04 /dev/sdb6
brwx------ 1 root root  8, 23 Nov 28 12:04 /dev/sdb7
brwx------ 1 root root  8, 24 Nov 28 12:04 /dev/sdb8

Why have I got both sd devices and dsk devices?
And what is the second line?
Why have I got an entry:
crw------- 1 root root 21,  0 Nov 28 11:45 /dev/dsk0_0

This looks like a generic device, but if so, why only one?
And where are the normal sg devices?




If I change the order of the disks on the SCSI bus, the
'generic' entry changes to dsk1_0. It seems to be associated
with the first disk encountered in the bus scan.
My disks are in a SCSI shelf and dsk1 is now in a
lower-numbered slot than dsk0.

[root@dev1 ~]# ls -l /dev/dsk* /dev/sd* /dev/sg*
brwx------ 1 root root  8, 16 Nov 28 16:05 /dev/dsk0_
brwx------ 1 root root  8, 17 Nov 28 16:05 /dev/dsk0_1
brwx------ 1 root root  8,  0 Nov 28 16:05 /dev/dsk1_
crwx------ 1 root root 21,  0 Nov 28 16:05 /dev/dsk1_0
brwx------ 1 root root  8,  1 Nov 28 16:05 /dev/dsk1_1
brwx------ 1 root root  8,  2 Nov 28 16:05 /dev/dsk1_2
brwx------ 1 root root  8,  3 Nov 28 16:05 /dev/dsk1_3
brwx------ 1 root root  8,  4 Nov 28 16:05 /dev/dsk1_4
brwx------ 1 root root  8,  5 Nov 28 16:05 /dev/dsk1_5
brwx------ 1 root root  8,  6 Nov 28 16:05 /dev/dsk1_6
brwx------ 1 root root  8,  7 Nov 28 16:05 /dev/dsk1_7
brwx------ 1 root root  8,  8 Nov 28 16:05 /dev/dsk1_8
brwx------ 1 root root  8,  0 Nov 28 16:05 /dev/sda
brwx------ 1 root root  8,  1 Nov 28 16:05 /dev/sda1
brwx------ 1 root root  8,  2 Nov 28 16:05 /dev/sda2
brwx------ 1 root root  8,  3 Nov 28 16:05 /dev/sda3
brwx------ 1 root root  8,  4 Nov 28 16:05 /dev/sda4
brwx------ 1 root root  8,  5 Nov 28 16:05 /dev/sda5
brwx------ 1 root root  8,  6 Nov 28 16:05 /dev/sda6
brwx------ 1 root root  8,  7 Nov 28 16:05 /dev/sda7
brwx------ 1 root root  8,  8 Nov 28 16:05 /dev/sda8
brwx------ 1 root root  8, 16 Nov 28 16:05 /dev/sdb
brwx------ 1 root root  8, 17 Nov 28 16:05 /dev/sdb1


Is this all as expected?
Am I going to be screwed later on if I need to do something
that requires a generic SCSI device for a particular disk?
Why do I still get /dev/sd* entries?
Any clues anyone?

Cheers,
Terry.



[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux