Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 6 May 2001 12:06:55 +1200
From:      "Juha Saarinen" <juha@saarinen.org>
To:        "Doug Russell" <drussell@saturn-tech.com>, "Matt Dillon" <dillon@earth.backplane.com>
Cc:        "freebsd-stable" <freebsd-stable@FreeBSD.ORG>
Subject:   RE: soft update should be default 
Message-ID:  <KPECIILENDDLPCNIMLOFMEKECDAA.juha@saarinen.org>
In-Reply-To: <Pine.BSF.4.21.0105051736310.95873-100000@beastie.saturn-tech.com>

next in thread | previous in thread | raw e-mail | index | archive | help
:: Yes, yes, yes!  No argument there.  People should realize what they are
:: doing by enabling the write cache, softupdates or no softupdates.

In my experience, very few people even know that there is such a thing as a
write-cache setting on hard drives. Also, most hard drives today ship with
write-caching enabled, without tools to turn it off.

Someone mentioned a sysctl that can be used to turn off drive
write-caching... which one is it?

I asked my friend Daryl Jay, who as the tech manager of a systems integrator
has had plenty of experience with hard drives in various situations, about
write caching.

Daryl says WCE has always been a problem; Windows 9x and ME can suffer file
system corruption with IDE hard drives that have large caches, as they can
become corrupted during an APM/ACPI shutdown -- MS issued a patch to for
Win98SE and WinME, but not fo the older variants, that increases the delay
before power-off to permit the cache contents to be written out.

He also confirms that if you have a SCSI RAID controller with onboard cache,
and set WCE for the drives / array as a whole, you have to have a UPS or a
battery to avoid f/s corruption.

However, a transaction / journalled file system such as NTFS, XFS and
ReiserFS goes a long way towards mitigating the effects of incomplete cache
write-outs. OTOH, FAT16/32 and Linux Ext2fs are very vulnerable in this
respect. No idea how UFS w/ or w/o softupdates performs here, unfortunately.

Daryl says that IBM drives are less likely to cause corruption, as they
shipped with a decently-sized power capacitor which in most cases will have
enough power to complete the cache write-out. This doesn't help with caching
SCSI controllers, obviously.

IBM used to ship all its drives with WCE set to off, and charged a fee to
have the drive "AV optimised", which was just a simple procedure to turn WCE
on. As of 2-3 years ago, all IBM drives are shipped with WCE on, however.

The performance drop you see when you turn off WCE is substantial. Daryl and
a customer tested a 36GB IBM Scorpion with and without WCE... without, they
got 3.2MBps average sustained DTR across the disk, with, 17.8MBps.

Just a few datapoints, in case anyone's interested... I think this should be
documented in the manual.

-- Juha


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




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