disk write barriers
From: Matthias Buelow (mkb_at_incubus.de)
Date: 07/06/05
- Previous message: jdyke: "make distribution fails with call to cap_mkdb"
- Next in thread: Lowell Gilbert: "Re: disk write barriers"
- Reply: Lowell Gilbert: "Re: disk write barriers"
- Maybe reply: Matthias Buelow: "Re: disk write barriers"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
To: freebsd-questions@freebsd.org Date: Wed, 06 Jul 2005 15:18:53 +0200
Hi folks,
I'd like to know something about the (possible) existence of disk
write-barriers in FreeBSD. I often read the advice that one should
disable write-back caching on modern disks in order to make softupdates
actually work. Unfortunately, disabling the write-back cache on typical
ATA/SATA consumer disks involves a severe performance hit (my Seagate
SATA drive here drops to 1/5th sequential write speed, probably worse
for a random workload, and so this workaround isn't really an option.)
Now I've stumbled across: http://lkml.org/lkml/2005/5/15/88 in which
someone claims that FreeBSD "used ... write barriers long ago".
Write-barriers are a kind of synchronization point around critical
writes (i.e., those which need to be kept in a certain order), where the
block level drivers disable (or flush) the cache before the barrier, and
reenable it afterwards. Windows has been doing that for a long time in
order to make their NTFS halfway reliable (amazing that they got
something right). Linux apparently also has write-barriers, although for
SATA only in the most recent 2.6 kernels.
Now my question is: Does FreeBSD also implements these barriers, or an
equivalent mechanism, as claimed on the above URL? If it does, why then
the frequent advice to disable write-back caching? Or is that only for
the couple drives that ignore any flush cache/disable wb commands? I
know my drive doesn't ignore that command (since performance drops
sharply, when I disable the cache), so I would be on the safe side.
Would it be possible to get an authoritative statement from a FreeBSD
developer here on that matter?
Thanks.
mkb.
_______________________________________________
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"
- Previous message: jdyke: "make distribution fails with call to cap_mkdb"
- Next in thread: Lowell Gilbert: "Re: disk write barriers"
- Reply: Lowell Gilbert: "Re: disk write barriers"
- Maybe reply: Matthias Buelow: "Re: disk write barriers"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]