Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 07 Dec 2005 14:05:40 +0000
From:      Dieter <freebsd@sopwith.solgatos.com>
To:        freebsd-questions@freebsd.org
Subject:   Disk write caching, hw.ata.wc and atacontrol disagree
Message-ID:  <200512072205.WAA17272@sopwith.solgatos.com>

next in thread | raw e-mail | index | archive | help
I'm trying to turn off the evil data corrupting on-disk write cache.

I added hw.ata.wc=0 to /boot/loader.conf and rebooted.

# sysctl hw.ata.wc    
hw.ata.wc: 0

So far so good.  But! atacontrol cap ad4 says:

Feature                      Support  Enable    Value           Vendor
write cache                    yes      yes

So hw.ata.wc thinks that the disk write cache is off,
but atacontrol cap thinks the disk write cache is on?

If it matters:  AMD64, nforce4, Seagate SATA 7200.8, FreeBSD 6.0 Beta3

So then I boot NetBSD and turn the write caches off with
	dkctl $disk setcache r
and reboot FreeBSD and now I get

Feature                      Support  Enable    Value           Vendor
write cache                    yes      no

It appears that if hw.ata.wc = 1 then FreeBSD turns the write
cache on, and if hw.ata.wc = 0 then FreeBSD leaves the write
cache alone?

Is there a way to have FreeBSD turn the write cache OFF?



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