Bonjour,
I desperately search how to see how the extends of a Logical Volume are distributed on the disks that make up the Volume Group. Especially when the Logical Volume is mirrored between 2 different storage array.
The idea behind this check is :
- to detect if a logical volume is mirrored on two volumes from a same array
- to verify wich extends are not synchronized
I had a case where one of my client configured a volume group with several disk from a given array, several from a second array, and has created a logical volume mirrored on the same array ... :-(
Under HP-UX we can simply control the localisation of extends of a logical volume whith lvdisplay and -v option. It doesn't work under Linux.
Exemple with vg01 which owns 2 disks from an array (disk12 en disk23) and 2 disks from another array (disk114 and disk142)
root@kskckca:/# lvdisplay -v /dev/vg01/lvol1
--- Logical volumes ---
LV Name /dev/vg01/lvol1
VG Name /dev/vg01
LV Permission read/write
LV Status available/syncd
Mirror copies 1
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 69988
Current LE 17497
Allocated PE 34994
Stripes 0
Stripe Size (Kbytes) 0
Bad block NONE
Allocation strict
IO Timeout (Seconds) default
--- Distribution of logical volume ---
PV Name LE on PV PE on PV
/dev/disk/disk12 17497 17497
/dev/disk/disk114 17494 17494
/dev/disk/disk23 3 3
--- Logical extents ---
LE PV1 PE1 Status 1 PV2 PE2 Status 2
00000000 /dev/disk/disk12 00000000 current /dev/disk/disk114 00003821 current
00000001 /dev/disk/disk12 00000001 current /dev/disk/disk114 00003822 current
00000002 /dev/disk/disk12 00000002 current /dev/disk/disk114 00003823 current
.../...
00017494 /dev/disk/disk12 00017494 current /dev/disk/disk23 00006241 current
00017495 /dev/disk/disk12 00017495 current /dev/disk/disk23 00006242 current
00017496 /dev/disk/disk12 00017496 current /dev/disk/disk23 00006243 current
Here I can see that almost all extends of this LV are mirrored between disk12 (my first test array) and disk114 (a volume from a second array). OK.
BUT the last 3 extends of the LV are mirrored between disk12 and disk23 ... that reside on the same storage array. Not good :-(
I can also see that all extends are synchronised : status = current
Is there anyway to get those useful informations under Linux ? I currently work with a Red Hat 7.3
Many thanks in advance
Eric