From nobody Mon May 4 07:17:05 2026 X-Original-To: dev-commits-src-all@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 4g8CdG1nrYz6cm1s for ; Mon, 04 May 2026 07:17:06 +0000 (UTC) (envelope-from git@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 4g8CdF6vH4z3KjJ for ; Mon, 04 May 2026 07:17:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1777879026; 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=xcUqEIiicYkpJJKTwBe1xA4A4/ZYbn4DXtg0MZdFVD4=; b=aj4AbTP9Lyp17ERhS/Wwjmhe9Homsy/GogI2qQmVTiVzXlg62CpTNgPo6BC+RL2Jlib+vx n8algnRllWVh4K0lDfr+twDuVCefIZyPOO4bYrxryeQqgbD9+ZDnfUmXGpovTgzowo4D9T PrWUvPP4aDol2TrV+ghjAUDnqEBKudOM6OVoRP0fEqstEEGtJ1xPJZzZggWi+BJb2YuQId Uy9eb3Iy4Ba0ZeiKQ33vThD9RAXCZJQ2nfZBPhwL4vGzSP4lbTz0A7sMK5SHuhVj72MqEO kRVzsB7hNXXYDoQnHxkRLD3SB9FmC7xWEKFznLv2bxWXtQkiz30wg5p6+rg8Fg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1777879026; a=rsa-sha256; cv=none; b=j32h6jvpFdCEnNssfR//MjMiE1907H+HnionGqVJyWS0gZSyRcBkcf29C+eAJmZdduGdAC vCqrV8216FfV+fcarkI1S47v09vB1Mw/+tlY13P1DKL7kW90mA7Jb8xT0lwcSxvZW3k+1c X4fM7xwORGg/cKfQcNPsz2KcBFCi3oAUo4KSMS+jQFqJOPDdqwxHN1ltxTXck8bu8nIivT awfRQpQcdtykN8iJ9RylSI/HmcisZjI8DjyhBgRZGstmd2sNqLaBYjRHJL0e2trM/R+hAc Omr8UpzN4iJHP5qMggDUSXwHYVOVIrvGPGY2hDZLwtn8KGxsnHcmAvrf31Tp/g== 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=1777879026; 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=xcUqEIiicYkpJJKTwBe1xA4A4/ZYbn4DXtg0MZdFVD4=; b=scyH/4rTnHaDitocl8jcwv1eBNTwR5TFi5dye5q7vgj6LavobmnyqZiaWhyV9PjRHcgRnP qE2ZU8Lmxg7JE4UTGtIp6EMIeOz/MsyLFO5kW42Xjvdd7RxFpfCi9kU6CqeH2eKQu+HzUY sZO/gS4FbArx0iJSOqUE3zLOxfGK0MzG2IKTLKmZsrsd63/RNBeeOETegk+BxrgU8WWLwJ OK2o0MuN+dbl6yuHWMASMkY+Km62n54CVce1ptsAalU8HIakIWtzeVgwKPm4AqrmmlfFqM LLLWtwqg4z2Rye3iArUjL9xuSva5x0wKw1YQowlB6S1AAS15DjbyR7t47quhlQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4g8CdF6VxBz18XG for ; Mon, 04 May 2026 07:17:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 40e8c by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 04 May 2026 07:17:05 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 350d980db869 - stable/15 - init.8: add RECOVERING section List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 350d980db8693b300fdee01598cb98c9699616ba Auto-Submitted: auto-generated Date: Mon, 04 May 2026 07:17:05 +0000 Message-Id: <69f847f1.40e8c.3b065f0@gitrepo.freebsd.org> The branch stable/15 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=350d980db8693b300fdee01598cb98c9699616ba commit 350d980db8693b300fdee01598cb98c9699616ba Author: Konstantin Belousov AuthorDate: 2026-04-26 10:28:05 +0000 Commit: Konstantin Belousov CommitDate: 2026-05-04 07:16:39 +0000 init.8: add RECOVERING section (cherry picked from commit e378d97eeb2b8961f312cc04d4751579a7b70741) --- sbin/init/init.8 | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/sbin/init/init.8 b/sbin/init/init.8 index f86adf53b361..85b1db2ddf06 100644 --- a/sbin/init/init.8 +++ b/sbin/init/init.8 @@ -401,6 +401,41 @@ Specifies the path used to search for the init binary. More than one binary can be listed in the string, candidate file names are split by the \[lq]:\[rq] separator. Each name is opened in sequence until a valid executable is found. +.Sh RECOVERING +If the +.Pa /sbin/init +binary is broken or cannot be executed by the current kernel, +recovery requires console access. +Then, the +.Va init_path +loader tunable can be used to specify alternative +.Nm +location. +.Pp +By default, system install leaves copy of the previous +.Nm init +binary at +.Pa /sbin/init.bak , +and this path is set as one component of the default +.Va init_path . +.Pp +If +.Nm +cannot be run, the +.Fx +version of +.Xr sh 1 +has a special provision for running as PID 1. +If the shell detects that it is running as init, it opens +.Pa /dev/console +as it standard input and output and enters the +command loop. +.Pp +The session should be exited using +.Ic reboot Fl q +or exec-ing fixed +.Nm , +since a normal exit will cause a kernel panic. .El .Sh FILES .Bl -tag -width /var/log/init.log -compact