Write cache, is write cache, is write cache?

Karl Pielorz kpielorz_lst at tdx.co.uk
Sat Jan 22 15:50:45 UTC 2011



--On 22 January 2011 03:10 -0800 Jeremy Chadwick <freebsd at jdc.parodius.com> 
wrote:

>> Write performance on the unit isn't that bad [it's not stunning] -
>> though with 4 drives in a mirrored set - it probably helps hide some
>> of the impact this option might have.
>
> I'm stating the below with the assumption that you have SATA disks with
> some form of AHCI-based controller (possibly Intel ICHxx or ESBx
> on-board), and *not* a hardware RAID controller with cache/RAM of its
> own:

It is an onboard AHCI based controller, it can do RAID 0/1 - but I'm using 
it as just JBOD / 1:1 (i.e. individual channels).

> Keep write caching *enabled* in the system BIOS.  ZFS will take care of
> any underlying "issues" in the case the system abruptly loses power
> (hard disk cache contents lost), since you're using ZFS mirroring.

Ok, I'll give it a whirl and see what it does to the performance. I was 
more concerned if ZFS would be writing data it doesn't want cached - and 
that BIOS setting effectively makes it cached.

> I have no idea why your BIOS setting for this option was disabled.  I do
> not know if it's the factory default either; you would have to talk to
> HP about that, or spend the time figuring out who was in the system BIOS
> last and how/if/why they messed around (the number of possibilities for
> why the option is disabled are endless).

It is the factory default. I have three of these machines (HP 
MicroServers), shipped from different suppliers - two had slightly older 
BIOS versions on, but *all* had Write Cache disabled in BIOS, both before & 
after the BIOS updates.

> You can use bonnie++ (ports/benchmarks/bonnie++) if you wish to do
> throughput and/or benchmark testing of sorts.

I'll have a look at those - I'm more interested in finding a tool that will 
write data both with, and without the "don't cache this" flag(s) set - to 
see if the performance is the same (you would hope that regardless of the 
BIOS setting that writing entirely data that's marked not to be cached, the 
performance would 'sink' back down to a sedate 12Mbytes/sec) - if it 
doesn't, something is lying somewhere :)

-Karl


More information about the freebsd-fs mailing list