On Tue, Mar 13, 2012 at 8:30 AM, C. L. Martinez <carlopmart at gmail.com>
wrote:> Hi all,
>
> ?I have strange problem with my persistent names applied to iscsi
> disks. I have configured an udev rule to assign static iscsi disk
> names:
>
> KERNEL=="sd[a-z]", SUBSYSTEM=="block",
PROGRAM="/sbin/scsi_id
> --whitelisted --replace-whitespace --device=/dev/$name",
> RESULT=="1iTGTDSK9a2c73ce654d0ca6", NAME="iscsi/sda"
> KERNEL=="sd[a-z][0-9]*", SUBSYSTEM=="block",
PROGRAM="/sbin/scsi_id
> --whitelisted --replace-whitespace --device=/dev/$name",
> RESULT=="1iTGTDSK9a2c73ce654d0ca6", NAME="iscsi/sda%n"
>
> ?When udev starts, it seems it works:
>
> [root at cossrv01 rules.d]# ls -la /dev/iscsi/sda
> brw-rw---- 1 root disk 8, 16 Mar 12 11:42 /dev/iscsi/sda
>
> After this, I try to create a lvm volume:
>
> [root at cossrv01 rules.d]# pvcreate /dev/iscsi/sda
>
> ?... and works. But:
>
> [root at cossrv01 rules.d]# pvdisplay
> ?--- Physical volume ---
> ?PV Name ? ? ? ? ? ? ? /dev/sdb
> ?VG Name ? ? ? ? ? ? ? cmdata
> ?PV Size ? ? ? ? ? ? ? 64.00 GiB / not usable 4.00 MiB
> ?Allocatable ? ? ? ? ? yes
> ?PE Size ? ? ? ? ? ? ? 4.00 MiB
> ?Total PE ? ? ? ? ? ? ?16382
> ?Free PE ? ? ? ? ? ? ? 12542
> ?Allocated PE ? ? ? ? ?3840
> ?PV UUID ? ? ? ? ? ? ? rSuu5T-VtRl-ffDd-5Vtm-CBhS-UffO-sFgCRX
>
> Why? Why pvdisplay doesn't shows /dev/iscsi/sda instead of /dev/sdb??
> It is a big problem when multiple iscsi disks are assigned in aleatory
> form ... and with CentOS 5.x this procedure works out of the box ...
> (with RHEL6.x doesn't works neither, but it works with RHEL5.x).
>
> Thanks.
Please, any help?