Date: Tue, 24 Aug 2004 09:43:40 -0400 From: John Baldwin <jhb@FreeBSD.org> To: freebsd-arch@FreeBSD.org Cc: Pawel Jakub Dawidek <pjd@FreeBSD.org> Subject: Re: Mounting root... Message-ID: <200408240943.40529.jhb@FreeBSD.org> In-Reply-To: <20040823214729.GX30151@darkness.comp.waw.pl> References: <20040823073559.GP30151@darkness.comp.waw.pl> <200408231716.31321.jhb@FreeBSD.org> <20040823214729.GX30151@darkness.comp.waw.pl>
next in thread | previous in thread | raw e-mail | index | archive | help
On Monday 23 August 2004 05:47 pm, Pawel Jakub Dawidek wrote: > On Mon, Aug 23, 2004 at 05:16:31PM -0400, John Baldwin wrote: > +> On Monday 23 August 2004 03:05 pm, Pawel Jakub Dawidek wrote: > +> > On Mon, Aug 23, 2004 at 11:46:12AM -0400, John Baldwin wrote: > +> > +> Why not have mirror create the provider instantly in an degraded > state +> > as soon +> as one disk shows up and then change from degraded > back to full +> > when the +> second disk finally arrives? Isn't this the > same case as +> > someone jerking the +> disk out at run time and then > shoving it (or a new +> > one) back in without +> rebooting? > +> > > +> > If it will be started in degraded mode, it can be mounted and modified > +> > before next components arrive, so there will be a need to rebuild > them. +> > +> How is this different from jerking the disk out of a running system and > then +> shoving it back in again? > > You don't want to rebuild a mirror on every boot after clean shutdown. > In most cases one can set kern.geom.mirror.timeout to 0 and there will be > no problem with this, because even after mirror start is degraded mode > new components are not rebuilt if there were no writes, but it will be > good to have more general solution... The fact that a RAID can recover when a disk goes away and comes back is already the "general solution" it seems. It works all the time, not just at boot, so it seems to me like you are trying to solve a problem that is already solved. I think at most you could maybe have a system wide delay before that the user can tweak via a tunable (rather than a per-GEOM class tunable like your mirror one) in order to optimize the boot code for these rare cases but that is about it. I.e., if a user notices that one of the disks always takes an extra second they can set the tunable to force the kernel to wait 2 seconds before trying to mount root. Any such delay should be centralized, however, and not per-class, since all the per-class delays would end up being cumulative, so if MIRROR waits 2 seconds and STRIPE waits 3 seconds then the entire process actually waits 5 seconds as opposed to letting the user tweak a single centralized timeout. -- John Baldwin <jhb@FreeBSD.org> <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" = http://www.FreeBSD.org
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200408240943.40529.jhb>