From nobody Mon May 17 14:54:11 2021 X-Original-To: bugs@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id D0BFB857495 for ; Mon, 17 May 2021 14:54:11 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4FkMbR52jQz3h1Q for ; Mon, 17 May 2021 14:54:11 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 94C456020 for ; Mon, 17 May 2021 14:54:11 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 14HEsBwi035491 for ; Mon, 17 May 2021 14:54:11 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 14HEsBa7035490 for bugs@FreeBSD.org; Mon, 17 May 2021 14:54:11 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 255945] FuseFS breaks Flock on FreeBSD 13 RELEASE Date: Mon, 17 May 2021 14:54:11 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 13.0-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Many People X-Bugzilla-Who: jSML4ThWwBID69YC@protonmail.com X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Bug reports List-Archive: http://lists.freebsd.org/bugs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-bugs@freebsd.org MIME-Version: 1.0 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D255945 Bug ID: 255945 Summary: FuseFS breaks Flock on FreeBSD 13 RELEASE Product: Base System Version: 13.0-RELEASE Hardware: amd64 OS: Any Status: New Severity: Affects Many People Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: jSML4ThWwBID69YC@protonmail.com Hello,=20 Flock no longer works on FreeBSD 13p0 when using FuseFS. This has been test= ed with two different fusefs clients.=20 Tested: MooseFS 3.0.115 from the ports tree.=20 Tested: fusefs-sshfs-3.7.1 from packages.=20 Here's a simple test to demonstrate the issue using sshfs.=20 1: Install fusefs-sshfs, flock, and bash. pkg install fusefs-sshfs flock bash 2: Create a sshfs mount. You can do this locally by allowing root login over ssh, or any other user. I'll use root to avoid any permission type issues.= =20 service sshd onestart mkdir /mnt/test sshfs root@127.0.0.1:/root /mnt/test The contents of /root should now be showing at /mnt/test 3: Create the test script at /mnt/test/flock-test.sh=20 ------------------- #!/usr/bin/env bash exec 200> ./lock.file echo "Acquire lock" flock -n 200 || exit 1 echo "Sleep 5 secs." sleep 5 echo "Release lock" flock -u 200 || exit 2 echo "Lock released" exit --------------- 4: Make the script executable chmod u+x flock-test.sh 5: Run the script twice.=20 ./flock-test.sh There seems to be different errors depending on if the 'lock.file' previous= ly exists.=20 Note, the same issue happens on MooseFS, but it's more complicated to setup. Here are MooseFS setup instructions, previously written for bug #245689, https://bz-attachments.freebsd.org/attachment.cgi?id=3D213598 The flock-test.sh script works as expected on FreeBSD 12.2. --=20 You are receiving this mail because: You are the assignee for the bug.=