From nobody Mon Sep 01 11:42:43 2025 X-Original-To: freebsd-current@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 4cFn712jd9z66Hyx for ; Mon, 01 Sep 2025 11:42:53 +0000 (UTC) (envelope-from junchoon@dec.sakura.ne.jp) Received: from www121.sakura.ne.jp (www121.sakura.ne.jp [153.125.133.21]) (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 mx1.freebsd.org (Postfix) with ESMTPS id 4cFn704xhvz3Q26 for ; Mon, 01 Sep 2025 11:42:52 +0000 (UTC) (envelope-from junchoon@dec.sakura.ne.jp) Authentication-Results: mx1.freebsd.org; none Received: from kalamity.joker.local (124-18-6-240.area1c.commufa.jp [124.18.6.240]) (authenticated bits=0) by www121.sakura.ne.jp (8.18.1/8.17.1/[SAKURA-WEB]/20201212) with ESMTPA id 581BghW7078938; Mon, 1 Sep 2025 20:42:44 +0900 (JST) (envelope-from junchoon@dec.sakura.ne.jp) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=dec.sakura.ne.jp; s=s2405; t=1756726966; bh=BF57LV+bw0JqRhncQ1YoOdX1+1hUIIZq1VQcmanunCg=; h=Date:From:To:Cc:Subject:In-Reply-To:References; b=kopqiS6JmNuy37gps4VD0BCaTy18b0xZfI57IBQXthmFjnWaLRg45dcM5cYiijJFj hx43p3oFx/I0ZT54YCGcFr0/zBDp37+KYahDHHC/QmsWMmVxmVx1/ZApogRZbPGSHG 6oZg0DlXiHetg/eT5D2rEJU0Mqi/1MmNjcuiUpQc= Date: Mon, 1 Sep 2025 20:42:43 +0900 From: Tomoaki AOKI To: Warner Losh Cc: Poul-Henning Kamp , Graham Perrin , FreeBSD-CURRENT Subject: Re: Using a recovery partition to repair a broken installation of FreeBSD Message-Id: <20250901204243.6548150b14d79d2eab04ad3d@dec.sakura.ne.jp> In-Reply-To: References: <7b384ac0-9b24-43a4-bf63-012d745155a7@gmail.com> <18e1a7e9-07d8-43a2-96af-0acdab6c2920@gmail.com> <20250901175827.73ba0ea24812cebe2263811f@dec.sakura.ne.jp> <202509010904.58194iP2007318@critter.freebsd.dk> Organization: Junchoon corps X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; amd64-portbld-freebsd14.3) List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@FreeBSD.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:7684, ipnet:153.125.128.0/18, country:JP] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Rspamd-Queue-Id: 4cFn704xhvz3Q26 On Mon, 1 Sep 2025 03:15:50 -0600 Warner Losh wrote: > On Mon, Sep 1, 2025, 3:05 AM Poul-Henning Kamp wrote: > > > -------- > > Tomoaki AOKI writes: > > > > > > > > > … it would be nice to have something like 'recovery partition', as > > > > some OSes have. or at least some tiny fail-safe feature. having remote > > > > machine in some distant datacenter, booting from a flashstick is > > always > > > > a problem. > > > > I thought that is what /rescue is for ? > > > > That only works if your boot loader can read it... I've thought for a > while now that maybe we should move that into a ram disk image that we fall > back to if the boot loader can't read anything else... > > Warner Exactly. If the loader (or bootcode to kick the loader in the partition/pool) can sanely read the partition/pool to boot from, I think /rescue is enough and no need for rescue "partition / pool". But once the partition / pool to boot is broken (including lost decryption key for encrypted partitions/drives from regular place), something others are needed. And what can be chosen to boot from BIOS/UEFI firmware depends on the implementation (some could restrict per-drive only, instead of every entry in EFI boot manager table). If BIOS/firmware allow to choose "drive" to boot, rescue "drive" is useful, if multiple physical drives are available. Yes, rescue mfsroot embedded into loader.efi would be a candidate, too, if the size of ESP allows. > > -- > > Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 > > phk@FreeBSD.ORG | TCP/IP since RFC 956 > > FreeBSD committer | BSD since 4.3-tahoe > > Never attribute to malice what can adequately be explained by incompetence. -- Tomoaki AOKI