pvdisplay does not show the correct PV size with large PVs
This document (7000151) is provided subject to the disclaimer at the end of this document.
SUSE Linux Enterprise Server 10
The metadata written to disk by the original lvcreate is wrong though, the metadata is not fixed by this update. Thus this has to be done manually. There are 2 different ways to fix the metadata:
- The first way is to delete and recreate the VG (all data will be lost!):
# vgremove VG-NAME
# vgcreate /dev/device VG-NAME
- The second way is to backup, modify and restore the VG configuration manually:
# vgcfgbackup -f /tmp/vgbackup VG-NAME
This command will backup the VG-configuration to the file /tmp/vgbackup
# grep dev_size /etc/lvm/archive/VG-NAME_00000.vg
This command will output the value from the inital creation of the VG, which is the correct value. The wrong value will be written to the VG config when the LV is created, so the file VG-NAME_00000.vg contains the correct value.
# edit /tmp/vgbackup
Now the file written by vgcfgbackup needs to be modified to contain the correct value from the last step. Replace the line containing"dev_size" by the line from the "grep" command above.
# vgcfgrestore -f /tmp/vgbackup VG-NAME
This will restore the modified VG configuration. From now on, the metadata in the LVM configuration is correct.
This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.
- Document ID:7000151
- Creation Date: 21-Apr-2008
- Modified Date:19-Mar-2021
- SUSE Linux Enterprise Desktop
- SUSE Linux Enterprise Server
For questions or concerns with the SUSE Knowledgebase please contact: firstname.lastname@example.org