LVM and VxVM

lv mirroring logical volume is spread across 2 disk but not striped

 
Glenn Mallard
Occasional Advisor

lv mirroring logical volume is spread across 2 disk but not striped

Need to move to new storage but logical volumes have space assigned from 2 disks. How can I move the extents to corresponding new disks with the extents assigned to old disk 1 going to new disk 1 and the rest of the extents assigned to old disk 2 going to new disk 2?
3 REPLIES 3
James R. Ferguson
Acclaimed Contributor

Re: lv mirroring logical volume is spread across 2 disk but not striped

Hi:

You could use distributed extent allocation and setup a {Physical Volume Group) for the new mirror.

Mirror from the old to the new disks and 'lvreduce -m 0) the old disk extents when done.

Regards!

...JRF...
Patrick Wallek
Honored Contributor

Re: lv mirroring logical volume is spread across 2 disk but not striped

You could also look into using 'pvmove'.

If you old disk is /dev/dsk/c1t2d3 and your new disk is /dev/dsk/c2t3d4 then you would use pvmove like:

pvmove /dev/dsk/c1t2d3 /dev/dsk/c2t3d4

This would move all extents from c1t2d3 to c2t3d4.
Noé
Valued Contributor

Re: lv mirroring logical volume is spread across 2 disk but not striped

You can do a lvextend from the old disks to the new disk:

lextend -m 1 lvol_to_move

And then you can do a lvreduce removing the old disks.

Regards.

Noe.