[linux-lvm] Forcing the lvconvert copy to be on a different physical disk
Mark H. Wood
mwood at IUPUI.Edu
Tue Jul 2 15:09:02 UTC 2013
On Mon, Jul 01, 2013 at 12:48:14PM +0200, Alessandro MACUZ wrote:
> in my company they want to use LVM to handle a transition period while
> moving VM guests from local datastore to a NAS (via iSCSI)
> An example with numbers is worth thousands of words.
> The idea is to have one leg locally and one leg on the NAS, then we'll
> remove the local leg and tha machine will run with the leg on the NAS.
> So there are two MBR-partitioned vdisks, 10G each, and with one big LVM
> partition (0x8e)
> I have created one VG spanning both disks and one LV hosted on the local
> How to tell lvconvert that the mirror, of the LV I want, must entirely be
> hosted on the second disk?
It looks as though you simply specify the PV from which you want to
allocate the new extents, after the LV you are mirroring. That is, if
you have a logical volume "LV" on /dev/sda1 and you want to mirror it
lvconvert -m1 LV /dev/sdb1
Later I think you would do likewise to remove the local image from
/dev/sda1, leaving the image on /dev/sdb1:
lvconvert -m0 LV /dev/sda1
*I have not yet done this*. Please try it out on a test machine
before risking production data.
Mark H. Wood, Lead System Programmer mwood at IUPUI.Edu
Machines should not be friendly. Machines should be obedient.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 198 bytes
Desc: Digital signature
More information about the linux-lvm