Copying a complete logical volume

Use this information as a guide for using the logical volume manager (LVM) cplv command to copy a complete logical volume.

The AIX LVM provides the cplv command for copying logical volumes within volume groups or to different volume groups. You can use this command to create a new logical volume while running the command, or you can overwrite an existing logical volume. The following two examples shows how to use the cplv command.
# cplv -v datavg -y newlv oldlv
 
# cplv -e existinglv oldlv 

In the first example, the cplv command copies data from the existing logical volume oldlv. It creates a new logical volume that it calls newlv (-y) in the volume group datavg (-v). If you omit the -v option, the volume group to which the existing logical volume belongs receives the new logical volume. When the cplv command creates a new logical volume, it creates the new volume with exactly the same characteristics as the existing logical volume.

In the second example, the cplv command copies data from existing logical volume oldlv to existing logical volume existinglv (-e). When you use the -e option, it overwrites the existing target-logical volume with the data from the source-logical volume. When you use the -e option, it maintains the characteristics of the existing target-logical volume. Take care when you use this option.

The cplv command is a good method for copying or migrating a single logical volume. Sometimes, however, you might need to migrate all the data from a physical volume.

Library | Support | Terms of use | Feedback
© Copyright IBM Corporation 2004, 2007. All Rights Reserved.