HP-UX 11i v3 - LVM Volume Group Version Migration (September 2010)
15
Verify the volume group
# vgdisplay vg01
--- Volume groups ---
VG Name /dev/vg01
VG Write Access read/write
VG Status available
Max LV 2047
Cur LV 0
Open LV 0
Cur Snapshot LV 0
Max PV 2048
Cur PV 1
Act PV 1
Max PE per PV 16368
VGDA 2
PE Size (Mbytes) 4
Unshare unit size (Kbytes) 1024
Total PE 1021
Alloc PE 0
Current pre-allocated PE 0
Free PE 1021
Total PVG 0
Total Spare PVs 0
Total Spare PVs in use 0
VG Version 2.2
VG Max Size 65472m
VG Max Extents 16368
Cur Snapshot Capacity 0p
Max Snapshot Capacity 65472m
Migrating a Version 2.2 volume group to Version 2.0
Verify that all prequisites are met
Run vgversion in review mode. The volume group can be active while running vgversion in
review mode. If any of the migration prerequisites are not met, the review option lists them. You must
correct any prerequisites that are not met. The following example shows the migration of a Version
2.2 volume group with a snapshot logical volume configured:
# vgversion -r -V 2.0 vg01
vgversion: Error: The specified volume group contains snapshot logical volumes.
Please delete the snapshot logical volumes for vgversion to proceed.
Review complete. Volume group not modified
In this example, the volume group vg01 has a snapshot logical volume configured. This causes the
volume group migration to fail. To remove the snapshot logical volume, use the lvremove command.
For example:
# lvremove /dev/vg01/lvol1_S2
The logical volume "/dev/vg01/lvol1_S2" is not empty;
do you really want to delete the logical volume (y/n) : y
Logical volume "/dev/vg01/lvol1_S2" has been successfully removed.
Volume Group configuration for /dev/vg01 has been saved in /etc/lvmconf/vg01.conf
Perform the migration
After all of the prerequisites are met, deactivate the volume group and run vgversion. For example:
# vgchange -a n vg01
Volume Group configuration for /dev/vg01 has been saved.
Volume group "vg01" has been successfully changed.