[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aQNNZ6lxeMntTifa@amir-ThinkPad-T480>
Date: Thu, 30 Oct 2025 12:35:03 +0100
From: Amir Goldstein <amir73il@...il.com>
To: "Darrick J. Wong" <djwong@...nel.org>
Cc: zlang@...hat.com, neal@...pa.dev, fstests@...r.kernel.org,
linux-ext4@...r.kernel.org, linux-fsdevel@...r.kernel.org,
joannelkoong@...il.com, bernd@...ernd.com
Subject: Re: [PATCH 22/33] generic/631: don't run test if we can't mount
overlayfs
On Tue, Oct 28, 2025 at 06:26:09PM -0700, Darrick J. Wong wrote:
> From: Darrick J. Wong <djwong@...nel.org>
>
> This test fails on fuse2fs with the following:
>
> +mount: /opt/merged0: wrong fs type, bad option, bad superblock on overlay, missing codepage or helper program, or other error.
> + dmesg(1) may have more information after failed mount system call.
>
> dmesg logs the following:
>
> [ 764.775172] overlayfs: upper fs does not support tmpfile.
> [ 764.777707] overlayfs: upper fs does not support RENAME_WHITEOUT.
>
> From this, it's pretty clear why the test fails -- overlayfs checks that
> the upper filesystem (fuse2fs) supports RENAME_WHITEOUT and O_TMPFILE.
> fuse2fs doesn't support either of these, so the mount fails and then the
> test goes wild.
>
> Instead of doing that, let's do an initial test mount with the same
> options as the workers, and _notrun if that first mount doesn't succeed.
>
> Fixes: 210089cfa00315 ("generic: test a deadlock in xfs_rename when whiteing out files")
> Signed-off-by: "Darrick J. Wong" <djwong@...nel.org>
> ---
> tests/generic/631 | 22 ++++++++++++++++++++++
> 1 file changed, 22 insertions(+)
>
>
> diff --git a/tests/generic/631 b/tests/generic/631
> index 72bf85e30bdd4b..64e2f911fdd10e 100755
> --- a/tests/generic/631
> +++ b/tests/generic/631
> @@ -64,6 +64,26 @@ stop_workers() {
> done
> }
>
> +require_overlayfs() {
> + local tag="check"
> + local mergedir="$SCRATCH_MNT/merged$tag"
> + local l="lowerdir=$SCRATCH_MNT/lowerdir:$SCRATCH_MNT/lowerdir1"
> + local u="upperdir=$SCRATCH_MNT/upperdir$tag"
> + local w="workdir=$SCRATCH_MNT/workdir$tag"
> + local i="index=off"
> +
> + rm -rf $SCRATCH_MNT/merged$tag
> + rm -rf $SCRATCH_MNT/upperdir$tag
> + rm -rf $SCRATCH_MNT/workdir$tag
> + mkdir $SCRATCH_MNT/merged$tag
> + mkdir $SCRATCH_MNT/workdir$tag
> + mkdir $SCRATCH_MNT/upperdir$tag
> +
> + _mount -t overlay overlay -o "$l,$u,$w,$i" $mergedir || \
> + _notrun "cannot mount overlayfs"
> + umount $mergedir
> +}
> +
> worker() {
> local tag="$1"
> local mergedir="$SCRATCH_MNT/merged$tag"
> @@ -91,6 +111,8 @@ worker() {
> rm -f $SCRATCH_MNT/workers/$tag
> }
>
> +require_overlayfs
> +
> for i in $(seq 0 $((4 + LOAD_FACTOR)) ); do
> worker $i &
> done
>
I agree in general, but please consider this (untested) cleaner patch
Thanks,
Amir.
View attachment "0001-generic-631-don-t-run-test-if-we-can-t-mount-overlay.patch" of type "text/x-diff" (2304 bytes)
Powered by blists - more mailing lists