gvinum start volume returns EBUSY
Stijn Hoop
stijn at win.tue.nl
Tue May 2 06:32:26 UTC 2006
On Mon, May 01, 2006 at 03:27:11PM -0500, Rick C. Petty wrote:
> When rebuilding a degraded plex with "gvinum start volume" on a mounted
> filesystem, gvinum reports "errno: 16" (EBUSY). In the CVS:
>
> src/sys/geom/vinum/geom_vinum_init.c, lines 363-364 (of MAIN, added
> 2005-Oct-09, rev 1.10.2.1) has the check:
>
> if (gv_is_open(p->geom))
> return (EBUSY);
>
> Why is this the case? The log for that change suggests this is to prevent
> sync operations from starting when they are already in progress, but that
> really refers to lines 366-367:
>
> if (p->flags & GV_PLEX_SYNCING)
> return (EINPROGRESS);
>
> It seems to me that lines 363-364 should be deleted. If you have a
> degraded volume but need to keep it mounted (such as /usr or /home, etc.),
> I can't see any reason why you should be forced to unmount the volume
> before rebuilding (if the volume is RAID5). Maybe this restriction is
> useful for non-RAID5 configurations, but gv_rebuild_plex is only called
> in the context of GV_PLEX_RAID5 on degraded plexes.
>
> Maybe I'm misunderstanding something. Feel free to enlighten me! :-)
While regular vinum allowed rebuilding plexes that were mounted, I have
seen resulting filesystem corruption afterwards.
Unfortunately I don't know whether Lukas has implemented & tested
rebuilding online plexes for gvinum yet.
--Stijn
More information about the freebsd-hackers
mailing list