Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 19 Oct 2002 21:37:06 -0700
From:      David Schultz <dschultz@uclink.Berkeley.EDU>
To:        Poul-Henning Kamp <phk@critter.freebsd.dk>
Cc:        Maxim Sobolev <sobomax@FreeBSD.ORG>, hackers@FreeBSD.ORG, dillon@FreeBSD.ORG
Subject:   Re: Patch to allow a driver to report unrecoverable write errors to the buf layer
Message-ID:  <20021020043706.GA23972@HAL9000.homeunix.com>
In-Reply-To: <28472.1035014051@critter.freebsd.dk>
References:  <3DB048B5.21097613@FreeBSD.org> <28472.1035014051@critter.freebsd.dk>

next in thread | previous in thread | raw e-mail | index | archive | help
Thus spake Poul-Henning Kamp <phk@critter.freebsd.dk>:
> >I noticed that FreeBSD buf/bio subsystem has one very annoying problem
> >- once the write request is ejected into it, and write operation
> >failed, there seemingly no way valid to tell the layer to drop the
> >buffer. Instead, it retries the attempt over and over again, until
> >reboot, even though originator of request (usually vfs layer) was
> >already notified about failure and propagated error condition to the
> >underlying user-lever program.
> 
> Yes, I noticed that appeared at some time.  That misfeature should be
> removed in toto.
> 
> If a retry can solve the issue, it's the drivers responsibility to
> retry as much as makes sense and then fail if it doesn't work.
> 
> Neither the buf nor the bio layer should get involved in those
> retries.

Yeah, I mentioned this problem back in April when I wrote a (still
uncommitted) one-line patch to fix an infinite loop in the msdosfs
code involving write failures.  It seems like you absolutely have
to be able to propagate failures up to higher layers in order to
solve the retry problem.  Otherwise, transient errors
(e.g. removing and then reinserting a floppy disk) would cause
filesystem corruption because the vnode layer would be unaware
that some buffers had been dropped.  How hard would it be to fix this?

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021020043706.GA23972>