From nobody Sun Nov 13 09:23:19 2022 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 4N96SR6Pxkz4hNhQ for ; Sun, 13 Nov 2022 09:23:35 +0000 (UTC) (envelope-from marklmi@yahoo.com) Received: from sonic310-20.consmr.mail.gq1.yahoo.com (sonic310-20.consmr.mail.gq1.yahoo.com [98.137.69.146]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 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 4N96SR3TGqz40Q8 for ; Sun, 13 Nov 2022 09:23:35 +0000 (UTC) (envelope-from marklmi@yahoo.com) Authentication-Results: mx1.freebsd.org; none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1668331412; bh=F3jnvmLgqN1hIyqFTQg2hnuzg9Dsw/L2GtrmhGb6YJs=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From:Subject:Reply-To; b=WHDxgshCHh+OBwlX2/htaW0rsyX1Gjc0jZ6MgGYf8bCmn/DvsUop6Va2WsWpBAcZT5HV6IdC3IZB2SSf9P8FlVVDK2DIhP2Hy899rvuTlJGHxhR2QJ+WANJ3Mbk2wyt8XMs7NMsjKGmzeqxsiEMqhxldIkexAmmTfurlh+EjG+V2ONCxVTWtoJbnmP3hVtjkdcPCHyw6eeWO6rb/YgdSpSuHtebFCYySIpOMLZm4K0HW1cbpF7kqq0TsfjZnoPUXflXUplqF7OZrgtcJkoqAWPBPGKQ1puWl4TlONETeDdKdp7ERvsZXpYZUuZLALfCJ6A/9MAcptITVBc/K5Qe0sg== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1668331412; bh=iRmExUImY6TasepzYDGUT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j1l.HaDDytb23n9iEn.nlwsG3RfO86ZKDhV.QaPCSzSelnZK4c9vPOro1Z1b5aJRpzvzf7J OEabmSKfqKlwaOOlrIF4xu13o10XFMq0RKKasjComp8cTDblOdR6ipYZR0xKqNxsU3_LYB_Glo6S sX8d.v31qttg8fletIfTnTE5Gi36bszQNJTjRkIDbdt0httCVsRmYMHvsfpHY2RlFD69ozvUPugw bjpKqryQY2dUElhoW.WbGpiQ70BcpPyax6hPPBoDtyiiiLtgKGuiwgyFIFfoPtSiWDS7WKstJfs7 dUBsMoO.KgYCu1WH46dSlnpxFzZ0TtZLZRZYYGln_hUq.n.wmOAFrR.oN5qnNRzsePEBOrdo4i9h YEH_Lqbrj6hbYzxEDhB1p33BvsKSDwQAVZdq7QTzDj6xOLCZ.B9WeiLFTyCRZ79ADCCbBF.KafqO N4XCsxRK4T5zWoRPO1tneL24wULOJO4yjml.oiW.NQ6073d6jhjEQzRSMkU0krpZ9NvdGZC_0aN9 tgl8tyALeQLr6D5qIVx5VQAKWIOq_45I5O3pQQxrc9pkLeAaV4RI_2ht32wf_kySeOOrU6388PjA - X-Sonic-MF: Received: from sonic.gate.mail.ne1.yahoo.com by sonic310.consmr.mail.gq1.yahoo.com with HTTP; Sun, 13 Nov 2022 09:23:32 +0000 Received: by hermes--production-gq1-579bc4bddd-hwj6j (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID 901d7d142b7665aebbf93ae8853e7dd7; Sun, 13 Nov 2022 09:23:30 +0000 (UTC) Content-Type: text/plain; charset=us-ascii 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 (Mac OS X Mail 16.0 \(3731.200.110.1.12\)) Subject: Re: Odd sysctl -d kern.bootfile result From: Mark Millard In-Reply-To: Date: Sun, 13 Nov 2022 01:23:19 -0800 Cc: freebsd-current Content-Transfer-Encoding: quoted-printable Message-Id: References: To: Kyle Evans X-Mailer: Apple Mail (2.3731.200.110.1.12) X-Rspamd-Queue-Id: 4N96SR3TGqz40Q8 X-Spamd-Bar: ---- X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:36647, ipnet:98.137.64.0/20, country:US] X-ThisMailContainsUnwantedMimeParts: N On Nov 12, 2022, at 20:42, Kyle Evans wrote: > On Sat, Nov 12, 2022 at 10:16 PM Mark Millard = wrote: >>=20 >> The context: >>=20 >> # ls -Tldt /boot/kern*/kernel >> -r-xr-xr-x 1 root wheel 40003240 Nov 6 16:32:05 2022 = /boot/kernel/kernel >> -r-xr-xr-x 1 root wheel 39990232 Jul 6 11:21:16 2022 = /boot/kernel.old/kernel >> -r-xr-xr-x 1 root wheel 31401824 Aug 19 03:16:29 2021 = /boot/kernel.dbg/kernel >>=20 >> # uname -apKU # Note: output line split for readability >> FreeBSD amd64_ZFS 14.0-CURRENT FreeBSD 14.0-CURRENT #55 >> main-n259064-f83db6441a2f-dirty: Sun Nov 6 16:31:55 PST 2022 >> = root@amd64_ZFS:/usr/obj/BUILDs/main-amd64-nodbg-clang/usr/main-src/amd64.a= md64/sys/GENERIC-NODBG >> amd64 amd64 1400073 1400073 >>=20 >>=20 >> But . . . >>=20 >> # sysctl -d kern.bootfile >> kern.bootfile: Name of kernel file booted >>=20 >> # sysctl -W kern.bootfile >> kern.bootfile: /boot/kernel.old/kernel >>=20 >> Looks wrong to me. (I've never explicitly assigned to kern.bootfile = .) >>=20 >=20 > The usual suspect here is that you did an `installkernel` -- if it > replaces kern.bootfile, it moves the old kern.bootfile to > /boot/kernel.old and updates the sysctl to reflect the new location so > that it still accurately reflects the booted kernel. Ahh: no, but, yes, sort of. For: # bectl list BE Active Mountpoint Space Created 13S-amd64 - - 4.96G 2021-08-20 16:57 13_0R-amd64 - - 4.30G 2021-08-20 16:56 13_1R-amd64 - - 3.76G 2022-03-10 12:38 main-amd64 NR / 7.26G 2022-11-06 20:02 old-main-amd64 - - 2.37G 2022-10-14 14:59 I normally boot main-amd64 but I also maintain the 13*-amd64's via mounting and chrooting into the 13*-amd64 be's and doing buildworld buildkernel and installkernel installworld while chrooted (no reboot). (I generate and boot an updated main-amd64 first.) The: kernel-install: .PHONY . . . sysctl kern.bootfile=3D${DESTDIR}${KODIR}.old/"`basename = "$$thiskernel"`" ; \ is apparently not local to the chroot's context but changes the booted system's live value despite the live system not being what was updated. The be entry usage is not essential here. chroot'ing into a directory tree used for the same sort of purpose for UFS (or ZFS) would have the same issue if installkernel was part of the activity. I may consider saving and restoring kern.bootfile in my 13*-amd64 procedures so that kern.bootfile does not end up being misleading. Thanks for the note! =3D=3D=3D Mark Millard marklmi at yahoo.com