Exposing the same VG from two different disks
Hi,
I'm not sure if what I'm trying to do is possible or not but hopefully someone out there can help!!
I have a volume group which consists of a LUN (/dev/emcpowerv1) in an EMC cabinet. To backup up the disk I use EMC technology to synchronise a second LUN (/dev/emcpoweraf1) with the first, when the synchronisation is complete I then break the connection. At this point I have two identical volume groups exposed to the same host. What I would like to do is rename the second volume group and mount its logical volumes. However I can't because (understandably) LVM doesn't like having two identical volume groups so when I issue pvchange -u I get...
# pvchange -u /dev/emcpoweraf1 Found duplicate PV dXiYI6nVqu8UpXO2mlaWiKKPKSBPrRbn: using /dev/emcpowerv1 not /dev/emcpoweraf1 get_pv_from_vg_by_id: vg_read failed to read VG ! /dev/emcpowerv1: write failed after 0 of 4096 at 4096: Operation not permitted pv_write with new uuid failed for /dev/emcpowerv1. 0 physical volumes changed / 1 physical volume not changed
Notice I issue the command against /dev/emcpoweraf1 but it complains about writing to /dev/emcpowerv1.
does anyone have any ideas?
Thanks in advance
Liam
Quoted 16 lines · On Fri, 2009-06-05 at 15:18 +0200, [email protected] wrote:
Hi,
I'm not sure if what I'm trying to do is possible or not but hopefully
someone out there can help!!I have a volume group which consists of a LUN (
/dev/emcpowerv1) in an
EMC cabinet. To backup up the disk I use EMC technology to synchronise a second LUN (/dev/emcpoweraf1) with the first, when the synchronisation is complete I then break the connection. At this point I have two identical volume groups exposed to the same host. What I would like to do is rename the second volume group and mount its logical volumes. However I can't because (understandably) LVM doesn't like having two identical volume groups so when I issue pvchange -u I get...
Quoted 8 lines
# pvchange -u /dev/emcpoweraf1 Found duplicate PV dXiYI6nVqu8UpXO2mlaWiKKPKSBPrRbn: using /dev/emcpowerv1 not /dev/emcpoweraf1 get_pv_from_vg_by_id: vg_read failed to read VG ! /dev/emcpowerv1: write failed after 0 of 4096 at 4096: Operation not permitted pv_write with new uuid failed for /dev/emcpowerv1. 0 physical volumes changed / 1 physical volume not changedNotice I issue the command against
/dev/emcpoweraf1but it complains about writing to/dev/emcpowerv1.
Take a look at the vgimportclone script posted to the lvm-devel list last month:
http://www.redhat.com/archives/lvm-devel/2009-May/msg00130.html
Regards,
Bryn.
Quoted 8 lines · On Fri, 5 Jun 2009, [email protected] wrote:
I have a volume group which consists of a LUN (
/dev/emcpowerv1) in an EMC cabinet. To backup up the disk I use EMC technology to synchronise a second LUN (/dev/emcpoweraf1) with the first, when the synchronisation is complete I then break the connection. At this point I have two identical volume groups exposed to the same host. What I would like to do is rename the second volume group and mount its logical volumes. However I can't because (understandably) LVM doesn't like having two identical volume groups so when I issue pvchange -u I get...
This is doable but tricky. Please read back a few weeks in the archives to find a script that is being polished to automate this. I forget the name of the person who did the script, but when you find the posts, give him a big thank you. Test the script carefully in your situation and report here.
Signature · 4 lines
Stuart D. Gathman <[email protected]> Business Management Systems Inc. Phone: 703 591-0911 Fax: 703 591-6154 "Confutatis maledictis, flammis acribus addictis" - background song for a Microsoft sponsored "Where do you want to go from here?" commercial.