Subject: Re: wd, disk write cache, sync cache, and softdep.
To: Daniel Carosone <firstname.lastname@example.org>
From: Pavel Cahyna <email@example.com>
Date: 12/16/2004 10:30:27
> On Thu, Dec 16, 2004 at 09:50:39AM +0100, Pavel Cahyna wrote:
> > Thanks for your analysis. I thought I'm alone in thinking that having
> > softdeps carefully ordering writes and the disk carefully destroying that
> > ordering, especially when the write cache is on by default, is a serious
> > bug in NetBSD.
> Not so much a bug as a deployment choice (including the choice of
> hardware to purchase), but never mind the semantics.
IMHO this is a bug, because NetBSD documentation (such as
http://www.netbsd.org/Documentation/misc/#ffs-integ) puts emphasis on
doing the right thing if the system crashes, but users are not told to
turn off the write cache if they want to have this benefit.
Also, having write cache on with softdeps seems like a really bad
deployment choice, because that way you are exposed to softdeps bugs
without actually having a reliability advantage over much simpler async
mode. Again, this is not discussed in mount(8) or dkctl(8) documentation
> > What about adding the condition that the total size of all unsynced write
> > requests is greater than the size of on-disk cache?
> This might be a good one, if there's a standard way to query the disk
> for this information at probe time; i'm not sure there is. Having
I vaguely remember that hdparm on linux is able to print the cache size.