Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 6 Dec 2021 09:59:51 -0800
From:      John Baldwin <jhb@FreeBSD.org>
To:        Jessica Clarke <jrtc27@freebsd.org>, Eugene Grosbein <eugen@grosbein.net>
Cc:        Ed Maste <emaste@FreeBSD.org>, "src-committers@freebsd.org" <src-committers@FreeBSD.org>, "dev-commits-src-all@freebsd.org" <dev-commits-src-all@FreeBSD.org>, "dev-commits-src-branches@freebsd.org" <dev-commits-src-branches@FreeBSD.org>
Subject:   Re: git: 0a2bc1aae36b - stable/12 - release: move installworld before installkernel
Message-ID:  <7d5db8fb-7cbd-d27a-7d59-59a50cbc4bb6@FreeBSD.org>
In-Reply-To: <409651DC-C965-4E47-A596-832C8EEB658C@freebsd.org>
References:  <202112031520.1B3FK0Yh010104@gitrepo.freebsd.org> <0ceb1866-07a1-9ba8-8ea4-104329ca7cb8@grosbein.net> <409651DC-C965-4E47-A596-832C8EEB658C@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 12/3/21 12:28 PM, Jessica Clarke wrote:
> On 3 Dec 2021, at 20:20, Eugene Grosbein <eugen@grosbein.net> wrote:
>>
>> 03.12.2021 22:20, Ed Maste wrote:
>>
>>> The branch stable/12 has been updated by emaste:
>>>
>>> URL: https://cgit.FreeBSD.org/src/commit/?id=0a2bc1aae36b44b2c9e16684bc6270b8a82943e2
>>>
>>> commit 0a2bc1aae36b44b2c9e16684bc6270b8a82943e2
>>> Author:     Ed Maste <emaste@FreeBSD.org>
>>> AuthorDate: 2021-04-05 17:16:01 +0000
>>> Commit:     Ed Maste <emaste@FreeBSD.org>
>>> CommitDate: 2021-12-03 15:19:09 +0000
>>>
>>>     release: move installworld before installkernel
>>>
>>>     To support -DNO_ROOT work.  The top-level installworld target creates a
>>>     new METALOG starting with `#mtree 2.0` so it needs to be first, to avoid
>>>     overwriting installkernel METALOG entries.
>>>
>>>     Reviewed by:    gjb
>>>     MFC after:      1 month
>>>     Sponsored by:   The FreeBSD Foundation
>>>     Differential Revision:  https://reviews.freebsd.org/D29582
>>
>> The need to run installworld before installkernel makes remote major upgrade less reliable:
>> in case of unexpected reboot in process a system ends up with new binaries that may require new system calls
>> and old kernel. This is bad.
>>
>> Is it possible to enhance install* targets so they do not overwrite what needs to be kept intact
>> to restore ability to install new kernel first?
> 
> This is only for generating release images, hence the release: prefix
> and the fact it’s in release/. It has no bearing on the sequence used
> to update a running system.

That said, the way METALOG is handled here is a bit annoying, and we've had to do
some hacks in cheribuild to deal with this.  It would be nice IMO if installworld
wrote to METALOG.world, and installkernel wrote to METALOG.${INSTKERNNAME} (or
something similar to permit METALOG.kernel and METALOG.kernel.GENERIC, etc.) and
then steps that needed a full METALOG concatenated the relevant METALOG.* files
to generate a merged file.

-- 
John Baldwin



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?7d5db8fb-7cbd-d27a-7d59-59a50cbc4bb6>