All of lore.kernel.org
 help / color / mirror / Atom feed
From: Shreeya Patel <shreeya.patel@collabora.com>
To: fstests@vger.kernel.org
Cc: linux-fsdevel@vger.kernel.org, krisman@collabora.com,
	preichl@redhat.com, kernel@collabora.com, willy@infradead.org,
	djwong@kernel.org
Subject: [PATCH v2] generic/631: Add a check for extended attributes
Date: Mon,  3 May 2021 15:56:54 +0530	[thread overview]
Message-ID: <20210503102654.196661-1-shreeya.patel@collabora.com> (raw)

Test case 631 fails for filesystems like exfat or vfat or any other
which does not support extended attributes.

The main reason for failure is not being able to mount overlayfs
with filesystems that do not support extended attributes.
mount -t overlay overlay -o "$l,$u,$w,$i" $mergedir

Above command would return an error as -
/var/mnt/scratch/merged0: wrong fs type, bad option, bad superblock
on overlay, missing codepage or helper program, or other error.

dmesg log reports the following -
overlayfs: filesystem on '/var/mnt/scratch/upperdir1' not supported

As per the overlayfs documentation -
"A wide range of filesystems supported by Linux can be the lower
filesystem, but not all filesystems that are mountable by Linux
have the features needed for OverlayFS to work. The lower filesystem
does not need to be writable. The lower filesystem can even be another
overlayfs. The upper filesystem will normally be writable and if it
is it must support the creation of trusted.* and/or user.* extended
attributes, and must provide valid d_type in readdir responses,
so NFS is not suitable. A read-only overlay of two read-only
filesystems may use any filesystem type."

As per the above statements from the overlayfs documentation,
it is clear that filesystems that do not support extended
attributes or d_type would not work with overlayfs.
This is why we see the error in dmesg log for upperdir1
which had an exfat filesystem.

This test case already checks for d_type but does not check for
extended attributes, hence add a check for it which would avoid
running this tests for filesystems that are not supported.

Signed-off-by: Shreeya Patel <shreeya.patel@collabora.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
---

Changes in v2
  - Wrap the commit messages at 75 columns.
  - Improve the commit message to mention about d_type check.


 tests/generic/631 | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tests/generic/631 b/tests/generic/631
index c43f3de3..c7f0190e 100755
--- a/tests/generic/631
+++ b/tests/generic/631
@@ -39,10 +39,12 @@ _cleanup()
 
 # get standard environment, filters and checks
 . ./common/rc
+. ./common/attr
 
 # real QA test starts here
 _supported_fs generic
 _require_scratch
+_require_attrs
 test "$FSTYP" = "overlay" && _notrun "Test does not apply to overlayfs."
 _require_extra_fs overlay
 
-- 
2.30.2


                 reply	other threads:[~2021-05-03 10:27 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20210503102654.196661-1-shreeya.patel@collabora.com \
    --to=shreeya.patel@collabora.com \
    --cc=djwong@kernel.org \
    --cc=fstests@vger.kernel.org \
    --cc=kernel@collabora.com \
    --cc=krisman@collabora.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=preichl@redhat.com \
    --cc=willy@infradead.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.