From nobody Sat May 23 21:46:54 2026 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 4gNG276JT9z6dvgH for ; Sat, 23 May 2026 21:46:55 +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 "R13" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4gNG271W7zz3fmm for ; Sat, 23 May 2026 21:46:55 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1779572815; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yxqdQRUkEoejfe20DhqICQEngmvIyPdGlN1SWtwRrt4=; b=GMzpFN9EtnAFeDoJgVlu6WfVMw4bRTOwS2Qx8AX7868+67DkvfDT+sk18zMzyUWMXvjPYy DayuROq428h+cV49Trrx0Hp27r4cRxfDquo/5Y0BZvDjx62VGhqcJnr4sm636+yCxzu55H OKQ+OGe8s7GBfsGdpT0DqOKOVhGj5/r6sJztryPsXBlSPYRqNq+MEhgl3ua+o3qcbjU1jQ 2VCDdZl6n0PZSKXj+1j959lXf+BhJy6sMhjGPYOv7XaRoqiypAuSEWo3IRO+48m/WgcHzv fU4le+nDteScDqD0pLmf6cwZ467W6Ngc9j3d+Ue8OhkJXsvSbLrH0VziX/pdVA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1779572815; a=rsa-sha256; cv=none; b=DuCr5LQayQ2V4khRupIjZG7QktzVfNsLdH9AALeOhSto/mwBy1IIreoS5FAHtF0CCjgE/0 n+PL8kbECwyFH0KsjkQDUwOwNH3CiDQfsXcr4Gj3U28x1qPoz1Qig+bWJawJ+/Mwq0wUfZ 7QJGfgXBkacDtX4vjdOKwJiIqMCchtLFhQ/rCxaLz4h13/e1y2baLkOKRtbhyp+M7IrW13 8+19vySvJKm423Ncga4Rl10KNTyo8UhbZ6ZU5odzeMAsbenyOlYMP4BRzkZFxPvYKVPF2/ 7LCHAczU+Jibt3qWu9NVYKWe0NAW+IGopQYagn4mZxaSmogzPxYoUIE4Zxov6A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1779572815; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yxqdQRUkEoejfe20DhqICQEngmvIyPdGlN1SWtwRrt4=; b=bnOBGj4pZUtgyI1p+kwqCAwAavGsMGSbPrxkUTCz9FB8L0dtOTlXwxW5m91L5erc15yCo6 fKL1L1ERh7sGXSk9iwNszUubTfMz994P0UHvfnlzXsSa1cPR850AnJhqo8DMC9jMfGCwlz NWwf3jJqdzrTON8hO6XRzK6mrLTexuFEaUnJHgOgfiqWbXRKAzT+k3PXgI22YbVeKd0Q/b N3ngXDPNc5RQnBe644HmwlMsuMQ94XzcDeNrUA+AP4kQqSZ6esCz9g2sH2sCGRTuSLP+0K EO3YnUQ9YIJhybnUHIUdnzeAzLJ4w7zzoOl9N70TApZUhppz0w/CgWh98WoyTA== 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 4gNG270Nkbz8wf for ; Sat, 23 May 2026 21:46:55 +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 64NLksYd002784 for ; Sat, 23 May 2026 21:46:54 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 64NLksYp002783 for bugs@FreeBSD.org; Sat, 23 May 2026 21:46:54 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 295532] lock order reversal zfs and ufs Date: Sat, 23 May 2026 21:46:54 +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: 16.0-CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: jfc@mit.edu 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-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="UTF-8" X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Bug reports List-Archive: https://lists.freebsd.org/archives/freebsd-bugs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-bugs@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D295532 Bug ID: 295532 Summary: lock order reversal zfs and ufs Product: Base System Version: 16.0-CURRENT Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: jfc@mit.edu Today running 16-CURRENT in bhyve I had a lock order reversal with zfs and = ufs named and nullfs implied. Given the stack trace and concurrent system activity, I figure poudriere was cleaning up its ZFS filesystems at the end of a build. The build filesyste= ms had nullfs mounts leading back to UFS /usr/src. Root filesystem (UFS) includes /usr/src. Poudriere master filesystem (ZFS) has a nullfs mount of root filesystem /usr/src. Builder filesystem (ZFS) has a nullfs mount of master filesystem usr/src. But there are four null_lock calls in the stack trace, not three. I might = have missed a filesystem. lock order reversal: 1st 0xfffff80c0f52d908 zfs (zfs, lockmgr) @ /usr/src/sys/kern/vfs_mount.c:= 2299 2nd 0xfffff80005a55c78 ufs (ufs, lockmgr) @ /usr/src/sys/fs/nullfs/null_vnops.c:851 lock order ufs -> zfs established at: #0 0xffffffff80c2f16b at witness_checkorder+0x35b #1 0xffffffff80b80f1a at lockmgr_lock_flags+0x16a #2 0xffffffff811db702 at VOP_LOCK1_APV+0x32 #3 0xffffffff80cd9123 at _vn_lock+0x53 #4 0xffffffff80cbeb19 at vflush+0xe9 #5 0xffffffff8305885a at zfs_umount+0xda #6 0xffffffff80cb28b4 at dounmount+0x664 #7 0xffffffff80cb21fc at kern_unmount+0x35c #8 0xffffffff8110ba08 at amd64_syscall+0x168 #9 0xffffffff810db0ab at fast_syscall_common+0xf8 lock order zfs -> ufs attempted at: #0 0xffffffff80c2faa7 at witness_checkorder+0xc97 #1 0xffffffff80b80f1a at lockmgr_lock_flags+0x16a #2 0xffffffff80f615fd at ffs_lock+0x8d #3 0xffffffff811db702 at VOP_LOCK1_APV+0x32 #4 0xffffffff82e89229 at null_lock+0x169 #5 0xffffffff811db702 at VOP_LOCK1_APV+0x32 #6 0xffffffff82e89229 at null_lock+0x169 #7 0xffffffff811db702 at VOP_LOCK1_APV+0x32 #8 0xffffffff82e89229 at null_lock+0x169 #9 0xffffffff811db702 at VOP_LOCK1_APV+0x32 #10 0xffffffff80cd9123 at _vn_lock+0x53 #11 0xffffffff80cbeb19 at vflush+0xe9 #12 0xffffffff82e87fd0 at nullfs_unmount+0x50 #13 0xffffffff80cb28b4 at dounmount+0x664 #14 0xffffffff80cb21fc at kern_unmount+0x35c #15 0xffffffff8110ba08 at amd64_syscall+0x168 #16 0xffffffff810db0ab at fast_syscall_common+0xf8 --=20 You are receiving this mail because: You are the assignee for the bug.=