Sponsored link Serve your customers, not your servers, with VERIO Linux VPS. Full-access test-drive here. |
XFS and NULLS and power, oh myXFS and NULLS and power, oh myPosted Mar 12, 2008 13:32 UTC (Wed) by sandeen (guest, #42852)In reply to: Developer interview: Eric Sandeen on ext4 implementation by sbergman27 Parent article: Developer interview: Eric Sandeen on ext4 implementation People bring this up over and over, but rarely get it right. The XFS page has a FAQ about this. XFS does not leave garbage in datablocks after an unclean shutdown. Doing so would be a security hole. And, the filesystem is not explicitly zeroing anything - what is going on is that a truncate may happen which removes extents from a file, and then an extending write is done. Because XFS uses delayed allocation, which waits until flush to actualy allocate data blocks, it is possible that, depending on when the crash occurs, you have metadata on-disk with a file size but no extents - i.e., a sparse file. XFS is not explicitly zeroing any blocks; at this point in time the file has no blocks. And so you see nulls when you read, just as you would with a sparse file. Some of this has to do with applications (im)properly looking after their data - see for example Stewart Smith's LCA talk. Recent changes to XFS have alleviated this problem by forcing a flush on file close when a file has been through these operations. Also, this business about flux capacitors or whatnot in SGI hardware is total bunk, as far as I know. I know that this is taken as an article of faith on the interwebs, but I do not think it is correct. One big hardware issue w.r.t. any journaling filesystem is the write cache in disks, because the filesystem must know when writes are truly safe on disk. XFS has write barriers enabled by default whenever the underlying storage allows it which, despite some performance overhead, is critical to ensure filesystem integrity after a crash. Due to implementation details, XFS journaling may be more susceptible to write cache problems, but in general it will affect any journaling filesystem.
(Log in to post comments)
XFS and NULLS and power, oh my Posted Mar 13, 2008 5:27 UTC (Thu) by sbergman27 (subscriber, #10767) [Link] """ Also, this business about flux capacitors or whatnot in SGI hardware is total bunk, as far as I know. I know that this is taken as an article of faith on the interwebs, but I do not think it is correct. """ Thanks for the info. But about the capacitors, I was just repeating what Ted Tso has said. :-)
|
Copyright © 2008, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds
Powered by Rackspace Managed Hosting.