Actually if I remember rightly the problem is mathematically insoluble
> The application can avoid the wrong file problem by zeroing out data
> before releasing it to the OS to reallocate.
When you zero out the data what order do you want those writes in relative
to the rename
> An async fsync allows me to issue multiple fsyncs and then wait for
> all of them to complete, hopefully in the same framework that I would
> do async I/O (but that's an argument for another day).
Ok.. right that makes more sense. So you actually want 'begin_fsync' and
'wait_fsync_all' type stuff
> Doing reliabile transactions on disk is a hard problem. That is why oracle
> and friends have spent many man years of research on this kind of problem.
> Current unix mailers do the smoke mirrors and prayer bit to reduce the
> probability a little that is all, regardless of fs and os.
>
> Isn't the point of the operating system to try to make it as easy as
> possible to do these things correctly?
The OS doesnt have enough information. To do transactions you must know the
entire material that corresponds to the transaction and bound it. That isnt
something the kernel has the knowledge about.
The job of the OS is to make the simple things easy, and the hard possible.
Not to burden the simple with the cost of the hard. That why the chattr +S
is such a nice solution in many ways
Alan
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/