mirror of
git://sourceware.org/git/lvm2.git
synced 2025-09-15 13:44:18 +03:00
Check for missing_pv in vg_remove loop.
If a pv is missing, we should just skip it rather than checking the device size and failing the vgremove.
This commit is contained in:
@@ -566,6 +566,9 @@ int vg_remove(struct volume_group *vg)
|
|||||||
/* init physical volumes */
|
/* init physical volumes */
|
||||||
dm_list_iterate_items(pvl, &vg->removed_pvs) {
|
dm_list_iterate_items(pvl, &vg->removed_pvs) {
|
||||||
pv = pvl->pv;
|
pv = pvl->pv;
|
||||||
|
if (is_missing_pv(pv))
|
||||||
|
continue;
|
||||||
|
|
||||||
log_verbose("Removing physical volume \"%s\" from "
|
log_verbose("Removing physical volume \"%s\" from "
|
||||||
"volume group \"%s\"", pv_dev_name(pv), vg->name);
|
"volume group \"%s\"", pv_dev_name(pv), vg->name);
|
||||||
pv->vg_name = vg->fid->fmt->orphan_vg_name;
|
pv->vg_name = vg->fid->fmt->orphan_vg_name;
|
||||||
|
Reference in New Issue
Block a user