resampeling of a ZVOL that has been resized

Andrey V. Elsukov bu7cher at yandex.ru
Mon Apr 27 08:59:24 UTC 2015


On 25.04.2015 13:52, Willem Jan Withagen wrote:
> So it seems that although gpart understands that the ZVOL volume has
> grown, it does not take it far enough and set it to CORRUPTED and then
> let the user correct/grow it.

Can you try this patch?

Index: head/sys/geom/part/g_part_gpt.c
===================================================================
--- head/sys/geom/part/g_part_gpt.c	(revision 282044)
+++ head/sys/geom/part/g_part_gpt.c	(working copy)
@@ -760,7 +760,7 @@ g_part_gpt_resize(struct g_part_table *basetable,
 	struct g_part_gpt_entry *entry;

 	if (baseentry == NULL)
-		return (EOPNOTSUPP);
+		return (g_part_gpt_recover(basetable));

 	entry = (struct g_part_gpt_entry *)baseentry;
 	baseentry->gpe_end = baseentry->gpe_start + gpp->gpp_size - 1;

-- 
WBR, Andrey V. Elsukov

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 538 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-fs/attachments/20150427/149ea6aa/attachment.sig>


More information about the freebsd-fs mailing list