ufs2 / softupdates / ZFS / disk write cache

Simun Mikecin numisemis at yahoo.com
Mon Jun 22 12:19:02 UTC 2009


Dan Naumov wrote:
> Actually I think a need a few clarifications regarding ZFS:
> 1) Does FreeBSD honor the "flush the cache to disk now" commands issued by ZFS to the harrdive only when ZFS is used directly on top of a disk device directly or does this also work when ZFS is used on top of a slice/partition?
> 2) If we compare ZFS vs UFS+SU while using a regular "lying" SATA disk (with write cache enabled) under heavy IO followed by a power loss. Which one is going to recover better and why?
1) AFAIK on FreeBSD (in contrary to Solaris) there is no difference wheter you use a whole disk or a slice/partition.
2) I wouldn't use UFS+SU on [S]ATA disks because your background fsck will simetimes give up stating something like "unexpected softupdates inconsistency" (unless you had disabled write cache, which you don't really want to) and you will have to do a manual foreground fsck yourself.
The choice should (in my opinion) be: ZFS for amd64, UFS+gjournal for i386. Both (ZFS and UFS+gjournal) will not have any recovery penalty if you have write cache enabled.
If you have a controller with battery backup cache, you could even run ZFS with disabled cache flush (i don't know wheter it can be disabled on gjournal), but I'm not sure that you will get any real word performance improvement by doing it.


      


More information about the freebsd-fs mailing list