Alan. Repeat after me: "fsync()+close() is basically useless for any app
that expects user interaction under load".
That's a FACT, not an opinion.
Don't be silly. If you want data corruption, then you make people write
threaded applications. Yes, you may work for Intel now, but that doesn't
mean that you have to drink the insane cool-aid. Threading is HARD. Async
stuff is HARD.
We kernel people really are special. Expecting normal apps to spend the
kind of effort we do (in scalability, in error handling, in security) is
just not realistic.
I do agree that close() shouldn't do an fsync - simply for performance
reasons.
But I also think that the "we write meta-data synchronously, but then the
actual data shows up at some random later time" is just crazy talk. That's
simply insane. It _guarantees_ that there will be huge windows of times
where data simply will be lost if something bad happens.
And expecting every app to do fsync() is also crazy talk, especially with
the major filesystems _sucking_ so bad at it (it's actually a lot more
realistic with ext2 than it is with ext3).
So look for a middle ground. Not this crazy militant "user apps must do
fsync()" crap. Because that is simply not a realistic scenario.
Linus
--