Red Hat Bugzilla – Bug 505143
Automatic recovery of inconsistent volume groups fails when PVs are missing.
Last modified: 2010-01-11 22:57:44 EST
Created attachment 347281 [details]
QA testing of lvm2 uncovered that when a failed PV is re-added to a VG, lvm commands fail due to a failure in automatic inconsistency recovery (see comment #3 is bug #504699). This affects mirror recovery process. A preliminary patch is available to address this issue (attached).
I have verified that the proposed patch fixes the problem (test for this is now in the upstream LVM testsuite).
Nevertheless, I have encountered a different bug, which we probably want to fix, although this is not as critical right now. This is that vgreduce --removemissing does not update metadata on the PV(s) it is removing, so we wind up with inconsistent copies again. I guess the right behaviour would be for vgreduce --removemissing to try fixing metadata on the bad PV as well, in case it has been restored already. For now, the workaround is to use vgreduce vg bad_pv, which works as expected. The PV can then be put back in the VG. We cannot automatically take the PV back as non-missing, since this could lead to nasty corner cases.
Patch in lvm2-2_02_46-6_el5.
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.