btrfs fscked up, too?
btrfs fscked up, too?
Posted Mar 17, 2009 0:23 UTC (Tue) by bojan (subscriber, #14302)In reply to: btrfs fscked up, too? by endecotp
Parent article: Garrett: ext4, application expectations and power management
The best you can find is rename manual page, which talks about processes that are currently running on the system always seeing the file. That's it. No further guarantees are made.
Now, given that a directory is a file, you have to fsync that if you want to see what you wrote there on disk (i.e. rename). Similarly, you have to fsync the data of the file if you want to see it on disk. Combine the two with the fact that nothing is specified as to the order of commits in the absence of fsync and you get the unordered rename (when it comes to the picture on disk), which is still atomic when it comes to running processes. But, you'll never know if your process is seeing the buffers or what's on disk (for both the data and the directory) unless you actually fsync beforehand.
