HP-UX HB v13.00 Ch-13 - LVM

HP-UX Handbook Rev 13.00 Page 10 (of 110)
Chapter 13 LVM
October 29, 2013
vgcfgbackup(1M)
A copy of the LVM header is held within the file system in the LVM backup file
(/etc/lvmconf/*.conf). Any modification of the LVM structure, e.g. through LVM
commands like lvcreate, lvchange, vgextend, etc. will be automatically saved in the VGs
config file through vgcfgbackup(1M).
You can run vgcfgbackup(1M) manually at any time:
# vgcfgbackup vgXY
Volume Group configuration for /dev/vgXY has been saved in
/etc/lvmconf/vgXY.conf
The content of the backup file is binary but you can use the -l option of vgcfgrestore(1M)
to display at least the disks belonging to the VG:
# vgcfgrestore -l -n vgXY
Volume Group Configuration information in "/etc/lvmconf/vgXY.conf"
VG Name /dev/vgXY
---- Physical volumes : 1 ----
/dev/rdsk/c1t6d0 (Bootable)
If the LVM header has been accidentally overwritten or became corrupted on the disk
you can recover it from this backup file using vgcfgrestore.
You usually use vgcfgrestore in case of a disk failure in order to write the LVM header
from this backup file to the new disk:
# vgcfgrestore -n vgXY /dev/rdsk/c1t6d0
Volume Group configuration has been restored to /dev/rdsk/c1t6d0
NOTE: If you modify the LVM configuration but do not want the backup file to be
updated, use “-A n with the LVM command. Anyway - the previous configuration can
be found in /etc/lvmconf/*.conf.old.
NOTE: vgcfgrestore does not restore the LIF volume. This is done by mkboot.
/etc/lvmtab, /etc/lvmtab_p and vgscan(1M)
The files /etc/lvmtab and /etc/lvmtab_p contain information about all known VGs and
their PVs. It is mainly used by vgchange(1M) at VG activation time. lvmtab is used for
LVM 1.0 and is a binary file and lvmtab_p is used for LVM 2.x and is a ascii file. To
display the lvmtab file you can display the printable strings in that file using the
strings(1M) command: