All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Blake <eblake@redhat.com>
To: Eric Farman <farman@linux.ibm.com>
Cc: Kevin Wolf <kwolf@redhat.com>, Hanna Reitz <hreitz@redhat.com>,
	 qemu-block@nongnu.org, qemu-devel@nongnu.org,
	Matthew Rosato <mjrosato@linux.ibm.com>
Subject: Re: [PATCH v4 4/5] iotests/108: skip if fuse is unusable
Date: Thu, 8 Oct 2026 11:23:04 -0500	[thread overview]
Message-ID: <asbEypwIt_7BrynM@redhat.com> (raw)
In-Reply-To: <20260925194409.716498-5-farman@linux.ibm.com>

On Fri, Sep 25, 2026 at 09:44:08PM +0200, Eric Farman wrote:
> It is possible that the ability to fusermount is restricted
> to privileged users. Rather than waiting for this test to
> perform a mount and subsequently fail, perform a dummy mount
> early on and skip the tests if fuse is not usable.
> 
> Signed-off-by: Eric Farman <farman@linux.ibm.com>
> ---
>  tests/qemu-iotests/108 | 20 ++++++++++++++++++++
>  1 file changed, 20 insertions(+)
> 
> diff --git a/tests/qemu-iotests/108 b/tests/qemu-iotests/108
> index bf808b35125..fc3f7322678 100755
> --- a/tests/qemu-iotests/108
> +++ b/tests/qemu-iotests/108
> @@ -73,6 +73,26 @@ else
>          _notrun 'Passwordless sudo for losetup or FUSE support required, but' \
>                  'neither is available'
>      fi
> +
> +    # Test to see if fuse is usable or not (permissions, etc.)
> +    export_mp="$TEST_DIR/fuse-export"
> +    touch "$export_mp"
> +
> +    response=$($QSD \
> +        --blockdev null-co,node-name=export-node \
> +        --export fuse,id=fuse-export,node-name=export-node,mountpoint="$export_mp",allow-other=off \
> +        --daemonize \
> +        --pidfile "$TEST_DIR/qsd.pid" 2>&1)
> +    _notrun_on_fuse_error "$response"
> +
> +    if [ -f "$TEST_DIR/qsd.pid" ]; then
> +        qsd_pid=$(cat "$TEST_DIR/qsd.pid")
> +        kill -KILL "$qsd_pid"
> +        # Wait for process to exit (cannot `wait` because the QSD is daemonized)
> +        while [ -f "$TEST_DIR/qsd.pid" ]; do
> +            true
> +        done

This appears to go into an infinite loop on a machine I tested where
corporate policy software held the fuse mountpoint open long enough
that it caused a race condition in tearing things down.  I'm dropping
this one from my pull request, but 1-3 and 5 remain.

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.
Virtualization:  qemu.org | libguestfs.org



  reply	other threads:[~2026-10-08 16:24 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-25 19:44 [PATCH v4 0/5] iotests fixes Eric Farman
2026-09-25 19:44 ` [PATCH v4 1/5] iotests/nbd-in-qcow2-chain: use default machine Eric Farman
2026-09-25 19:44 ` [PATCH v4 2/5] iotests/nbd-tls-iothread: skip on non-x86 hardware Eric Farman
2026-09-25 19:44 ` [PATCH v4 3/5] iotests/fuse-truncate: skip if FUSE is not usable Eric Farman
2026-09-25 19:44 ` [PATCH v4 4/5] iotests/108: skip if fuse is unusable Eric Farman
2026-10-08 16:23   ` Eric Blake [this message]
2026-09-25 19:44 ` [PATCH v4 5/5] iotests/iothreads-nbd-export: Skip on s390 Eric Farman
2026-09-25 21:46 ` [PATCH v4 0/5] iotests fixes Eric Blake
2026-10-07 17:34   ` Eric Farman
2026-10-07 21:40     ` Eric Blake
2026-10-07 22:40       ` Eric Farman

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=asbEypwIt_7BrynM@redhat.com \
    --to=eblake@redhat.com \
    --cc=farman@linux.ibm.com \
    --cc=hreitz@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mjrosato@linux.ibm.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.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.