All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v1 0/3] io_tests fuse fixes
@ 2026-07-25 12:56 Eric Farman
  2026-07-25 12:56 ` [PATCH v1 1/3] iotests/108: skip test if cannot access /dev/fuse Eric Farman
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Eric Farman @ 2026-07-25 12:56 UTC (permalink / raw)
  To: Kevin Wolf, Hanna Reitz
  Cc: qemu-block, qemu-devel, Matthew Rosato, Eric Farman

Hi,

The following are three small fixes against some of the qemu iotests
to avoid some errors that should prevent the tests from running in
the first place. We noticed these on an s390 host, but I don't
believe that to be relevant. My hunch is the messages are slightly
different based on distro, because the tests (correctly) skip for
me running Fedora on s390 or x86_64 while they fail under Ubuntu 26.04.

Eric Farman (3):
  iotests/108: skip test if cannot access /dev/fuse
  iotests/file-io-error: complete permission denied check
  iotests/fuse-mmap-shared: complete permission denied check

 tests/qemu-iotests/108                    | 2 +-
 tests/qemu-iotests/tests/file-io-error    | 3 +++
 tests/qemu-iotests/tests/fuse-mmap-shared | 7 +++++--
 3 files changed, 9 insertions(+), 3 deletions(-)

-- 
2.53.0



^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH v1 1/3] iotests/108: skip test if cannot access /dev/fuse
  2026-07-25 12:56 [PATCH v1 0/3] io_tests fuse fixes Eric Farman
@ 2026-07-25 12:56 ` Eric Farman
  2026-07-25 12:56 ` [PATCH v1 2/3] iotests/file-io-error: complete permission denied check Eric Farman
  2026-07-25 12:56 ` [PATCH v1 3/3] iotests/fuse-mmap-shared: " Eric Farman
  2 siblings, 0 replies; 4+ messages in thread
From: Eric Farman @ 2026-07-25 12:56 UTC (permalink / raw)
  To: Kevin Wolf, Hanna Reitz
  Cc: qemu-block, qemu-devel, Matthew Rosato, Eric Farman

This test might fail if the user is not root (or sudo'd):

  fusermount3: failed to open .../scratch/qcow2-file-108/fuse-export: Permission denied

A check exists to try to cover for this, but there are
two potential error messages that signal this case
(per the comment block associated with the check) and
only a skip for one of them.

Add a check for the other potential error message.

Fixes: 9ffd6d646d ("iotests/108: Test new refcount rebuild algorithm")
Signed-off-by: Eric Farman <farman@linux.ibm.com>
---
 tests/qemu-iotests/108 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/qemu-iotests/108 b/tests/qemu-iotests/108
index bf808b3512..136007ceaf 100755
--- a/tests/qemu-iotests/108
+++ b/tests/qemu-iotests/108
@@ -69,7 +69,7 @@ else
     # or "Invalid parameter 'fuse'", depending on whether there is
     # FUSE support or not.
     error=$($QSD --export fuse 2>&1)
-    if [[ $error = *"'fuse'"* ]]; then
+    if [[ $error = *"'fuse'"* || $error = *"'id'"* ]]; then
         _notrun 'Passwordless sudo for losetup or FUSE support required, but' \
                 'neither is available'
     fi
-- 
2.53.0



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH v1 2/3] iotests/file-io-error: complete permission denied check
  2026-07-25 12:56 [PATCH v1 0/3] io_tests fuse fixes Eric Farman
  2026-07-25 12:56 ` [PATCH v1 1/3] iotests/108: skip test if cannot access /dev/fuse Eric Farman
@ 2026-07-25 12:56 ` Eric Farman
  2026-07-25 12:56 ` [PATCH v1 3/3] iotests/fuse-mmap-shared: " Eric Farman
  2 siblings, 0 replies; 4+ messages in thread
From: Eric Farman @ 2026-07-25 12:56 UTC (permalink / raw)
  To: Kevin Wolf, Hanna Reitz
  Cc: qemu-block, qemu-devel, Matthew Rosato, Eric Farman

As with iotests/108, there are multiple potential error messages
returned to the user. Add a 'notrun' exit for another possible
error that would otherwise cause this test to fail:

  fusermount3: failed to open TEST_DIR/fuse-export: Permission denied

Fixes: 380448464d ("tests/file-io-error: New test")
Signed-off-by: Eric Farman <farman@linux.ibm.com>
---
 tests/qemu-iotests/tests/file-io-error | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/tests/qemu-iotests/tests/file-io-error b/tests/qemu-iotests/tests/file-io-error
index fb8db73b31..86f8e1b6a6 100755
--- a/tests/qemu-iotests/tests/file-io-error
+++ b/tests/qemu-iotests/tests/file-io-error
@@ -92,6 +92,9 @@ output=$(_send_qemu_cmd $QEMU_HANDLE \
 if echo "$output" | grep -q "Parameter 'type' does not accept value 'fuse'"; then
     _notrun 'No FUSE support'
 fi
+if echo "$output" | grep -q "failed to open TEST_DIR/fuse-export: Permission denied"; then
+    _notrun 'No FUSE support'
+fi
 echo "$output"
 
 echo
-- 
2.53.0



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH v1 3/3] iotests/fuse-mmap-shared: complete permission denied check
  2026-07-25 12:56 [PATCH v1 0/3] io_tests fuse fixes Eric Farman
  2026-07-25 12:56 ` [PATCH v1 1/3] iotests/108: skip test if cannot access /dev/fuse Eric Farman
  2026-07-25 12:56 ` [PATCH v1 2/3] iotests/file-io-error: complete permission denied check Eric Farman
@ 2026-07-25 12:56 ` Eric Farman
  2 siblings, 0 replies; 4+ messages in thread
From: Eric Farman @ 2026-07-25 12:56 UTC (permalink / raw)
  To: Kevin Wolf, Hanna Reitz
  Cc: qemu-block, qemu-devel, Matthew Rosato, Eric Farman

As with iotests/108, there exists multiple messages that would
signal a permission error when accessing the fuse tests:

  fusermount3: failed to open .../scratch/qcow2-file-fuse-mmap-shared/export.fuse: Permission denied

Incorporate an additional potential error message to cause the
test to be skipped rather than failed.

Fixes: ba20257d9b ("iotests: test shared mmap for fuse export")
Signed-off-by: Eric Farman <farman@linux.ibm.com>
---
 tests/qemu-iotests/tests/fuse-mmap-shared | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/tests/qemu-iotests/tests/fuse-mmap-shared b/tests/qemu-iotests/tests/fuse-mmap-shared
index 52941a3bb6..faa302e4db 100755
--- a/tests/qemu-iotests/tests/fuse-mmap-shared
+++ b/tests/qemu-iotests/tests/fuse-mmap-shared
@@ -28,8 +28,11 @@ def test_fuse_support(mount_point):
     })
     test_qsd.stop()
     if 'error' in res:
-        assert (res['error']['desc'] ==
-                "Parameter 'type' does not accept value 'fuse'")
+        print(res)
+        assert ((res['error']['desc'] ==
+                "Parameter 'type' does not accept value 'fuse'") or
+                (res['error']['desc'] ==
+                "Failed to mount FUSE session to export"))
         iotests.notrun('No FUSE support')
 
 # Shared mmap when using direct IO is only supported for Linux kernels >= 6.6
-- 
2.53.0



^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2026-07-25 13:17 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-25 12:56 [PATCH v1 0/3] io_tests fuse fixes Eric Farman
2026-07-25 12:56 ` [PATCH v1 1/3] iotests/108: skip test if cannot access /dev/fuse Eric Farman
2026-07-25 12:56 ` [PATCH v1 2/3] iotests/file-io-error: complete permission denied check Eric Farman
2026-07-25 12:56 ` [PATCH v1 3/3] iotests/fuse-mmap-shared: " Eric Farman

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.