From: "Darrick J. Wong" <djwong@kernel.org>
To: Zorro Lang <zlang@redhat.com>
Cc: fstests <fstests@vger.kernel.org>, xfs <linux-xfs@vger.kernel.org>
Subject: [PATCH] generic/275: fix on 32k fsblock filesystems
Date: Wed, 9 Apr 2025 08:16:12 -0700 [thread overview]
Message-ID: <20250409151612.GJ6274@frogsfrogsfrogs> (raw)
From: Darrick J. Wong <djwong@kernel.org>
This test fails on 32k-fsblock filesystems:
dd: failed to open '/opt/tmp3': No space left on device
dd: failed to open '/opt/tmp4': No space left on device
Pre rm space:
Filesystem Type 1024-blocks Used Available Capacity Mounted on
/dev/sda4 xfs 2031616 2030624 992 100% /opt
Post rm space:
Filesystem Type 1024-blocks Used Available Capacity Mounted on
/dev/sda4 xfs 2031616 2030368 1248 100% /opt
could not sufficiently fill filesystem
On a 32k-fsblock filesystem, creating tmp3 and tmp4 requires more than
1MB for the transaction allocation, which is why this test fails to fill
the filesystem. To fix this, touch the four tmp files before trying to
use up all the free space. The fix in ef25a29fa49a50 was incomplete.
Cc: <fstests@vger.kernel.org> # v2022.07.24
Fixes: ef25a29fa49a50 ("generic/275: fix premature enospc errors when fs block size is large")
Signed-off-by: "Darrick J. Wong" <djwong@kernel.org>
---
tests/generic/275 | 3 +++
1 file changed, 3 insertions(+)
diff --git a/tests/generic/275 b/tests/generic/275
index fbfe158163f336..42d8ff00562ee7 100755
--- a/tests/generic/275
+++ b/tests/generic/275
@@ -43,6 +43,9 @@ _scratch_mount
# now when we know there's enough free blocks.
later_file=$SCRATCH_MNT/later
touch $later_file
+for i in 1 2 3 4; do
+ touch $SCRATCH_MNT/tmp$i
+done
# this file will get removed to create 256k of free space after ENOSPC
# conditions are created.
next reply other threads:[~2025-04-09 15:16 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-09 15:16 Darrick J. Wong [this message]
2025-04-10 6:24 ` [PATCH] generic/275: fix on 32k fsblock filesystems Christoph Hellwig
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250409151612.GJ6274@frogsfrogsfrogs \
--to=djwong@kernel.org \
--cc=fstests@vger.kernel.org \
--cc=linux-xfs@vger.kernel.org \
--cc=zlang@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox