LWN.net Logo

Delayed reaction

Delayed reaction

Posted Dec 5, 2009 1:29 UTC (Sat) by dlang (✭ supporter ✭, #313)
In reply to: Delayed reaction by foom
Parent article: Journal-guided RAID resync

note that this says it is tranactional when syncronous writes are desired. that is not the normal operation

second, it days that it uses an intent bitmap to implement this protection. this is one of the methods described in the article to address this problem

so ZFS didn't sidestep this issue, it implemented the same method that MD offers (which is usually disabled for performance reasons), write intent bitmaps.

I stand corrected on the COW issue, but by doing COW you have two major problems

1. every write to a file ends up updating many more places on the filesystem (the file block gets moved and re-written, then the metadata that points to that file gets moved and re-written, then the metadata that points to that metadata..... until the root directory gets re-written) this is one of the failues of btree filesystems that made them unusable on rotating media.

wikipedia states that ZFS works around this by buffering the writes to consolodate them, but that is the same strategy that ext3 uses, and the need to then write all that buffered data in the face of a sync call is why fsync is so horrible on ext3


(Log in to post comments)

Delayed reaction

Posted Dec 5, 2009 12:22 UTC (Sat) by paulj (subscriber, #341) [Link]

Note that the ZFS Intent Log doesn't affect the consistency of the filesystem. The fs is consistent without the intent log, thanks to the COW, Merkle tree arrangement. So its not solving any consistency problems, i.e.:

  • ZFS is transactional, with or without the ZIL
  • ZFS is always consistent on disk, with or without the ZIL

The ZIL is there to solve the problem of supporting performant synchronous writes. ZFS would still support consistent, synchronous writes without the ZIL, just they'd be very slow.

I think it'd be useful if you looked at this ZFS presentation, which is where I'm getting most of my info from. The OSOL ZFS community also has a source overview.

Delayed reaction

Posted Dec 5, 2009 12:31 UTC (Sat) by paulj (subscriber, #341) [Link]

A good blog entry on the ZIL.

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds