[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: dd und Dateisysteme



Heiko Schlittermann schreibt:

> Reproduzierbar hatte ich Probleme, wenn ich XFS auf LVM hatte und
> dann mutwillig einfach den Stecker gezogen habe.  Dann waren
> *reproduzierbar* Dateien leer (in denen vorher etwas war,
> tragischerweise war's bei mir die /etc/passwd, sonst hätte ich's
> vielleicht gar nicht bemerkt).

Wenn ich L<http://oss.sgi.com/projects/xfs/faq.html#nulls> richtig
verstehe, folgt dieses Problem aus der Arbeitsweise von XFS:

"XFS journals metadata updates, not data updates. After a crash you are
supposed to get a consistent filesystem which looks like the state
sometime shortly before the crash, NOT what the in memory image looked
like the instant before the crash.

Since XFS does not write data out immediately unless you tell it to
with fsync, an O_SYNC or O_DIRECT open (the same is true of other
filesystems), you are looking at an inode which was flushed out, but
whose data was not. Typically you'll find that the inode is not taking
any space since all it has is a size but no extents allocated (try
examining the file with the xfs_bmap(8) command)."



Reply to: