Allow pesize change to adjust free values
RFC 1/1 Allow pesize change to adjust free values
Hi folks
I run again over the problem that vgchange is able to change the size of a PE, but refuses to recalculate certain free values.
The attached patch seems to work for one PV but it it is not safe for more. It may change the following things:
- Number of extents in VG.
- Free space of VG.
- Number of extents in PV.
- Size of free PV segment.
Fix for the later: Do PV resize as in this patch. Collect numbers of removed extents and remove them from the VG.
tools/vgchange.c +0 -8
@@ -405,14 +405,6 @@return EINVALID_CMD_LINE ; } -if (extent_size > vg->extent_size) { -if ((uint64_t ) vg->extent_size * vg->extent_count % extent_size) { -/* FIXME Adjust used PV sizes instead */ -log_error ("New extent size is not a perfect fit" ); -return EINVALID_CMD_LINE ; - } - } -if (!archive (vg))return ECMD_FAILED ;
lib/metadata/metadata.c +28 -18
81 lines not on this page · raw message
Signature · 3 lines
Each kiss is as the first. -- Miramanee, Kirk's wife, "The Paradise Syndrome", stardate 4842.6