[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20130604190150.GR3030@thunk.org>
Date: Tue, 4 Jun 2013 15:01:50 -0400
From: Theodore Ts'o <tytso@....edu>
To: 宋柏翰 <solarispika@...il.com>
Cc: Eric Sandeen <sandeen@...hat.com>, linux-ext4@...r.kernel.org
Subject: Re: Question on delalloc
On Wed, Jun 05, 2013 at 01:30:22AM +0800, 宋柏翰 wrote:
> Though what I tried to
> said is that delalloc'd data will stop kjournald from writing them
> back when it would like to do so, therefore those delalloc'd data will
> stay in memory more longer than those non-delalloc'd ones.
That's not why when you enable delayed allocation data can stay in
memory longer than when delalloc is disabled (or when ext3 is used).
So you were wrong about why this happens, although the observation is
correct.
> As described in http://lwn.net/Articles/322823/.
Please note that the current behaviour vis-a-vis buffered writes and
when you they will written to disk is generally true for all modern
file systems: xfs, btrfs, and ext4. The workaround described at the
end of the above article has been adopted by all of the modern file
systems, as a workaround for buggy user space applications (which at
one point included core libraries for both GNOME and KDE); this
workaround however is __not__ guaranteed by POSIX, and there are other
operationg systems, such as MacOS X, where you can't guarantee on
these semantics.
(In fact with MacOS, by default fsync() is even weaker than what POSIX
guarantees; you need use fcntl(F_FULLSYNC) to get POSIX guarantees.)
More context can be found here:
http://blahg.josefsipek.net/?p=364
- Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists