From nobody Fri May 08 20:22:17 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 4gC0sT5Nn7z6cvlc for ; Fri, 08 May 2026 20:22:21 +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 4gC0sT4MVzz3r4Q for ; Fri, 08 May 2026 20:22:21 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1778271741; 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=9oNbpt8YeXvujEzijwggx8cbmQhIS5d0Coec4YzaNNI=; b=Qa9WsmXffAdBVNnWSn6rZ8/0LKfLgHNmksLU+bRNwlfj9kp+FdzUihm4KO435aSBCdz7PX oao9kOjeBIMyivoe1t0RC/eQWoByXWDIMdnnWr2xnJQFUEuTMaDxeoGCBPj3eOPvJ2BlBl 1OqEAlfLiKBeEMVJFpRwdd3f4ZA5SU603KEmsgVWPpAd/DYgnGhcK1Ssnn0hbBNaBGBaEM viMEn2nkBavoVnubIxPtrSKsQ77ue0lLCy6+Q9AG9pe6UhvhE504tv/7AOdrRqbjIyVMRN V4a9H6C/iGMuuoQKU+o6+TunZ2B+VAWiVRUhfe/sWa43Qp6F3q1tBYTRBrWIMQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1778271741; a=rsa-sha256; cv=none; b=cZYvJJfi8x2q05FKB22KRQkTvp7S44Hsq5JwPtuk5TmYBXCYiNJc/97PQecW02b1iea1YD Zvxx+mkC0Ara0T2K3RBkoN/emE+b2/8kAZHTMoJC04Jz0Xerr9cTLTdB7y4/SK1EbwZixd +XeZVioY3dF5nDE8z6A39t/vXlzS54+fnJQ77r88bLUNGTevSsyyeqDYy/UmQhnJXYIdqz WMcSDgBsHv7mRvoXB/5NB4Z+WJY+5r4saYvUQcgVs4UbN2/eqbxiJ5/HDDYkCuzrNQQMkP erx0QlWyxtVz4ewyv059DImqRWRyv76MIu/jDGqWOugFAn2UiwuLXDHw2bcaNw== 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=1778271741; 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=9oNbpt8YeXvujEzijwggx8cbmQhIS5d0Coec4YzaNNI=; b=WSV4vXPA69SEo8o85FeBOszeNBw6nu4x6XjwJLmIhyIw47vs0l1jsJH6umNRLwxs7NvODJ p1zg7hm4WSxl5ZA4hdpZUgECO2DZJu329DdF/JHCKJdKvoQ4d4cOEbMDj9RridNCyrluub WvusXD68pWEwJk5JU+AG1qjS2dsRgu3r2ZXrjOwnb9qPicvhTB1pqHSb6xSoX7hybwhoQP Fk0CpfvCrd5vc94rcnnuQifvcgXAAcbvf3uApmsXvnkVN9opWrXlZtzIpdduH8V5+Oqpct yEUPzY1BFVBFj/xD3cb9U5WcvWmMt3ZZwzLaZrIXFOERIvNgfr+egnXMmSqZww== 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 4gC0sT3wN4zCs3 for ; Fri, 08 May 2026 20:22:21 +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 648KMLNv019482 for ; Fri, 8 May 2026 20:22:21 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 648KMLwg019453 for bugs@FreeBSD.org; Fri, 8 May 2026 20:22:21 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 295107] Concurrent jail starts fail when invoked via rc.d Date: Fri, 08 May 2026 20:22:17 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: bin X-Bugzilla-Version: 15.0-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: sears@cs.berkeley.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=3D295107 Bug ID: 295107 Summary: Concurrent jail starts fail when invoked via rc.d Product: Base System Version: 15.0-RELEASE Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: bin Assignee: bugs@FreeBSD.org Reporter: sears@cs.berkeley.edu /etc/rc.d/jail incorrectly uses the process name 'jail' to see if the jail = it is attempting to start is already running. 'jail' is a short-lived CLI too= l, so if you run two jail starts (for instance) at the same time, the helpers = in rc.subr spuriously conclude that the jail has been started. I have scripts that reproduce the issue + test the fix, but they are AI-generated. I'll include them if requested. (I'm not sure how far the AI contribution policy extends.) I ran them against 15.0-RELEASE, and don't see any recent changes to /etc/rc.d/jail or any relevant-looking changes to rc.subr=20=20 The tests just start two different jails concurrently, each with a "sleep 1= " in an exec.prestart. One of the two always fails with an 'already running' er= ror. I did not notice any obvious problems when two jails are allowed to start at the same time. (The underlying tools and kernel mechanisms seem to do the right thing.) The fix is one line. Add this comment + line to /etc/rc.d/jail above 'jail_svcj=3D"NO"', and below 'load_rc_config $name': # Choose a non-matching string for procname to prevent rc.subr from default= ing # to "jail". Without this, operations against unrelated jails conflict if = they # both (or a user) are running the 'jail' cli tool concurrently. procname=3D: --=20 You are receiving this mail because: You are the assignee for the bug.=