From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 9821A15802C for ; Wed, 18 Dec 2024 14:30:23 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 020BEE08AB; Wed, 18 Dec 2024 14:30:17 +0000 (UTC) Received: from smarthost01b.sbp.mail.zen.net.uk (smarthost01b.sbp.mail.zen.net.uk [212.23.1.3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (prime256v1) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 8B96EE086A for ; Wed, 18 Dec 2024 14:30:15 +0000 (UTC) Received: from [82.69.80.10] (helo=cube.localnet) by smarthost01b.sbp.mail.zen.net.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) (envelope-from ) id 1tNv3e-0014Yd-NM for gentoo-user@lists.gentoo.org; Wed, 18 Dec 2024 14:30:13 +0000 From: Peter Humphrey To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] Fun with systemd-boot Date: Wed, 18 Dec 2024 14:30:12 +0000 Message-ID: <3620457.iIbC2pHGDl@cube> In-Reply-To: References: Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" X-Originating-smarthost01b-IP: [82.69.80.10] Feedback-ID: 82.69.80.10 X-Archives-Salt: 2079efc4-0dae-40eb-9982-4182aa48d990 X-Archives-Hash: 64dfa72a754e5a59a864132ff9599e0d On Wednesday 18 December 2024 12:13:59 GMT Alan Mackenzie wrote: > I've been having fun with systemd-boot. I've been using bootctl from systemd-utils for some years; ever since I=20 graduated to an EFI system. I don't follow the wiki because of the resultin= g=20 impenetrable thicket of unpronounceable names and 32-digit hex numbers. Fin= e=20 for a distro builder, perhaps, but not for me thank you - especially as I w= ant=20 a selection of kernels to boot from, which I never did work out how to achi= eve=20 following the official advice. My method has only one related USE variable: sys-apps/systemd-utils boot kernel-install My EFI partition, unformatted and not mentioned in /etc/fstab, is /dev/ nvme0n1p1. 0n1p2 is the FAT-32 /boot. # tree -L 3 /boot /boot =E2=94=9C=E2=94=80=E2=94=80 [config files from make install] =E2=94=9C=E2=94=80=E2=94=80 early_ucode.cpio =E2=94=9C=E2=94=80=E2=94=80 EFI =E2=94=82 =E2=94=9C=E2=94=80=E2=94=80 BOOT =E2=94=82 =E2=94=82 =E2=94=94=E2=94=80=E2=94=80 BOOTX64.EFI =E2=94=82 =E2=94=9C=E2=94=80=E2=94=80 Linux =E2=94=82 =E2=94=94=E2=94=80=E2=94=80 systemd =E2=94=82 =E2=94=94=E2=94=80=E2=94=80 systemd-bootx64.efi =E2=94=9C=E2=94=80=E2=94=80 intel-uc.img =E2=94=9C=E2=94=80=E2=94=80 loader =E2=94=82 =E2=94=9C=E2=94=80=E2=94=80 entries =E2=94=82 =E2=94=82 =E2=94=9C=E2=94=80=E2=94=80 06-gentoo-rescue-6.6.52= =2Econf =E2=94=82 =E2=94=82 =E2=94=9C=E2=94=80=E2=94=80 07-gentoo-rescue-6.6.52= =2Enonet.conf =E2=94=82 =E2=94=82 =E2=94=9C=E2=94=80=E2=94=80 08-gentoo-rescue-6.6.62= =2Econf =E2=94=82 =E2=94=82 =E2=94=9C=E2=94=80=E2=94=80 09-gentoo-rescue-6.6.62= =2Enonet.conf =E2=94=82 =E2=94=82 =E2=94=9C=E2=94=80=E2=94=80 30-gentoo-6.6.62.conf =E2=94=82 =E2=94=82 =E2=94=9C=E2=94=80=E2=94=80 32-gentoo-6.6.62.nox.co= nf =E2=94=82 =E2=94=82 =E2=94=94=E2=94=80=E2=94=80 34-gentoo-6.6.62.nonet.= conf =E2=94=82 =E2=94=9C=E2=94=80=E2=94=80 entries.srel =E2=94=82 =E2=94=9C=E2=94=80=E2=94=80 loader.conf =E2=94=82 =E2=94=94=E2=94=80=E2=94=80 random-seed =E2=94=9C=E2=94=80=E2=94=80 [System.map files from make install] =E2=94=9C=E2=94=80=E2=94=80 vmlinuz-6.6.38-gentoo-rescue =E2=94=9C=E2=94=80=E2=94=80 vmlinuz-6.6.52-gentoo =E2=94=9C=E2=94=80=E2=94=80 vmlinuz-6.6.52-gentoo-rescue =E2=94=9C=E2=94=80=E2=94=80 vmlinuz-6.6.62-gentoo =E2=94=94=E2=94=80=E2=94=80 vmlinuz-6.6.62-gentoo-rescue This is the relevant parts of the kernel make script on my little i5 NUC bo= x: cd /usr/src/linux time (make -j4 && make modules_install &&\ make install && rm -f /boot/*old) emerge @module-rebuild @x11-module-rebuild rm -f /boot/early_ucode.cpio.new &&\ iucode_tool -q -S --write-earlyfw=3D/boot/early_ucode.cpio.new \ -tr /boot/early_ucode.cpio -tb /lib/firmware/intel-ucode &&\ mv -v /boot/early_ucode.cpio.new /boot/early_ucode.cpio &&\ echo Then all I have to do is some simple mmv and sed -i on the files in /boot/ loader/entries and loader.conf. Also remove obsolete kernels, configs and m= aps=20 from /boot. Oh, and bootctl set-default 30-gentoo-6.6.62.conf if it's a rem= ote=20 machine and I won't be present at boot time. =2D-->8 > Could somebody perhaps suggest a better boot loader to me? I need to be > able to chose between several kernels at booting time, but I certainly > don't want something "refined" like grub - I just need what I thought > systemd-boot actually was before yesterday. That's even worse than what I was suffering until I developed my own system. > Thanks in advance! Hope that helps. =2D-=20 Regards, Peter.