diff options
author | Eric Sandeen <sandeen@redhat.com> | 2009-12-23 07:58:12 -0500 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2009-12-23 07:58:12 -0500 |
commit | c8afb44682fcef6273e8b8eb19fab13ddd05b386 (patch) | |
tree | 44c170427e54b611d7f02a31bbd5733cc9cf1dd0 /Documentation/development-process/2.Process | |
parent | 17bd55d037a02b04d9119511cfd1a4b985d20f63 (diff) |
ext4: flush delalloc blocks when space is low
Creating many small files in rapid succession on a small
filesystem can lead to spurious ENOSPC; on a 104MB filesystem:
for i in `seq 1 22500`; do
echo -n > $SCRATCH_MNT/$i
echo XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX > $SCRATCH_MNT/$i
done
leads to ENOSPC even though after a sync, 40% of the fs is free
again.
This is because we reserve worst-case metadata for delalloc writes,
and when data is allocated that worst-case reservation is not
usually needed.
When freespace is low, kicking off an async writeback will start
converting that worst-case space usage into something more realistic,
almost always freeing up space to continue.
This resolves the testcase for me, and survives all 4 generic
ENOSPC tests in xfstests.
We'll still need a hard synchronous sync to squeeze out the last bit,
but this fixes things up to a large degree.
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Diffstat (limited to 'Documentation/development-process/2.Process')
0 files changed, 0 insertions, 0 deletions