xfs
[Top] [All Lists]

Re: zero size file after power failure with kernel 2.6.30.5

To: Linux XFS <xfs@xxxxxxxxxxx>
Subject: Re: zero size file after power failure with kernel 2.6.30.5
From: pg_xf2@xxxxxxxxxxxxxx (Peter Grandi)
Date: Mon, 31 Aug 2009 23:10:44 +0000
In-reply-to: <4A99A80C.9010307@xxxxxxxxxxx>
References: <200908292102.21710@xxxxxx> <4A99A80C.9010307@xxxxxxxxxxx>
[ ... ]

>> Shouldn't it be that this doesn't happen anymore? I'd love to
>> be in a position where I really can rely on a crash not
>> trashing any of my files anymore.

Then 'mount' with '-o sync', or write your own applications and
patches to the GNU/Linux kernel to enforce well known atomicity
and persistence semantics.

This issue as related to several filesystems has been discussed
in great depth over the past several months. Consider reading
and if possible try to understand these contributions:

    http://sandeen.net/wordpress/?p=34
    http://sandeen.net/wordpress/?p=42
    https://bugs.edge.launchpad.net/ubuntu/+source/linux/+bug/317781/comments/45
    http://lwn.net/SubscriberLink/322823/e6979f02e5a73feb/
    
http://loupgaroublond.blogspot.com/2009/03/anecdote-about-why-doing-wrong-thing-is.html
    
http://thunk.org/tytso/blog/2009/03/12/delayed-allocation-and-the-zero-length-file-problem/
    http://mjg59.livejournal.com/108257.html
    http://www.csamuel.org/2009/04/11/default-ext3-mode-changing-in-2630
    http://tribulaciones.org/2009/03/is-ext4-unsafe/

>> I used to have reiserfs previously, and never, not a single
>> time despite many crashes, did I have such an issue. I'd
>> really be pleased so see such stability in XFS. I'm using
>> barriers - what else must I do?

Barriers under GNU/Linux regrettably only enforce ordering. It
is a POSIX weakness. Actual delays/semantics depend on kernel
version.

> this will depend on what kde is doing internally as well.

Unfortunately KDE like most applications is known not to do the
right thing (depending on specific app and version, but most IIRC).

[ ... ]

<Prev in Thread] Current Thread [Next in Thread>