From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id eBtgB+15yl6BSgAA0tVLHw (envelope-from ) for ; Sun, 24 May 2020 13:43:09 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id sEQ/A+15yl6IcAAAB5/wlQ (envelope-from ) for ; Sun, 24 May 2020 13:43:09 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 8CFF79403EC for ; Sun, 24 May 2020 13:43:08 +0000 (UTC) Received: from localhost ([::1]:34526 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jcquB-0002VV-5k for larch@yhetil.org; Sun, 24 May 2020 09:43:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40620) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jcqu6-0002TN-SI for guix-patches@gnu.org; Sun, 24 May 2020 09:43:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:53374) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jcqu6-0008Co-Jp for guix-patches@gnu.org; Sun, 24 May 2020 09:43:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jcqu6-0006NS-HV for guix-patches@gnu.org; Sun, 24 May 2020 09:43:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#41011] [PATCH] gnu: grub: Support for network boot via tftp/nfs. Resent-From: Danny Milosavljevic Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sun, 24 May 2020 13:43:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41011 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Stefan Cc: Mathieu Othacehe , 41011@debbugs.gnu.org Received: via spool by 41011-submit@debbugs.gnu.org id=B41011.159032776724494 (code B ref 41011); Sun, 24 May 2020 13:43:02 +0000 Received: (at 41011) by debbugs.gnu.org; 24 May 2020 13:42:47 +0000 Received: from localhost ([127.0.0.1]:36687 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jcqtr-0006Mz-3j for submit@debbugs.gnu.org; Sun, 24 May 2020 09:42:47 -0400 Received: from dd26836.kasserver.com ([85.13.145.193]:56002) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jcqtp-0006Mn-8v for 41011@debbugs.gnu.org; Sun, 24 May 2020 09:42:46 -0400 Received: from localhost (80-110-127-207.cgn.dynamic.surfer.at [80.110.127.207]) by dd26836.kasserver.com (Postfix) with ESMTPSA id 72CAA336396B; Sun, 24 May 2020 15:42:43 +0200 (CEST) Date: Sun, 24 May 2020 15:42:15 +0200 From: Danny Milosavljevic Message-ID: <20200524154215.1fdb0a94@scratchpost.org> In-Reply-To: <078D1EA7-0875-4F24-AA49-D39CCDC77403@vodafonemail.de> References: <9AAFEFF4-8ACE-4C95-975F-67C3F4FDAF81@vodafonemail.de> <87a72gi4kz.fsf@gmail.com> <1179D890-7D6C-43D8-A286-DA7A0F61D585@vodafonemail.de> <87h7w7cc55.fsf@gnu.org> <92DB8E2B-1CA2-41AE-9265-53C4F5337686@vodafonemail.de> <20200524125859.7efe5169@scratchpost.org> <078D1EA7-0875-4F24-AA49-D39CCDC77403@vodafonemail.de> X-Mailer: Claws Mail 3.17.5 (GTK+ 2.24.32; x86_64-unknown-linux-gnu) MIME-Version: 1.0 Content-Type: multipart/signed; boundary="Sig_/Yd/Y.Ar=_/91LQW_.QAyPZA"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.7 (-) X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Spam-Score: 0.39 X-TUID: bG05YBgKJw8Y --Sig_/Yd/Y.Ar=_/91LQW_.QAyPZA Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi Stefan, On Sun, 24 May 2020 15:09:02 +0200 Stefan wrote: > Hm, if I select an older system generation in GRUB, than that older one i= s booted. But this doesn't change the bootloader. Correct. It doesn't need to since it just changes which Linux kernel will = be booted temporarily, including what system and so on. "System" here excludes $HOME. Since the guix package manager itself is in $HOME, I think that that doesn'= t revert though. > If I then delete some system generations =E2=80=93 as I=E2=80=99ve seen s= o far, but I might be wrong =E2=80=93 the bootloader is not reinstalled eit= her. > Only the grub.cfg is regenerated to remove the deleted generations. You are totally right O_O reinstall-bootloader says: > ;; Only install bootloader configuration file. What happened here? Why?! (I think we should document these bootloader Guix intricacies in some bette= r place than the mailing list archives; can't keep the thing straight other= wise :P) >If I reboot, then I'm still using the latest generation GRUB, but boot som= e older system generation, which would not be able by itself to install thi= s very recent GRUB in use. It should be able to since guix package manager including package definitio= ns is in $HOME, which is not rolled back, I think. The only way to install= the very recent GRUB is guix system reconfigure, and that will totally be = able to see the newest guix packages. > If I then reconfigure the system, only then another GRUB - or even a diff= erent bootloader, depending on my etc/config.scm =E2=80=93 will be installe= d and the according configuration file will be generated as well. Then agai= n all will fit. Yes, that case is fine. > In the worst case the (bootloader (bootloader-configuration =E2=80=A6) = =E2=80=A6) in my etc/config.scm is still newer than this older guix system = in use is able to handle. I think guix-the-package-manager is not reverted, so it will be able to see= the newest installable stuff.=20 > Oh, by the way, does booting an older system generation also change the g= uix version in use from the latest 'guix pull'? I don't think it does. No, that is per-user and not per-system. > And does booting an older generation change the config.scm? I don=E2=80= =99t think so either. No. > Actually, I don=E2=80=99t really understand what you mean. Are there circ= umstances beside a 'guix system reconfigure' in which the bootloader gets r= einstalled? And with reinstall I don=E2=80=99t mean to only regenerate the = grub.cfg, but calling /sbin/grub-install. I think the actual bootloader (any of them those worked before) should be r= einstalled by guix system delete-generations too, but apparently it doesn't= do it right now. Sounds very dangerous. Doesn't that mean if one changed bootloaders in the= past and then keeps using guix system delete-generations, that one eventua= lly couldn't boot anymore? O_O > Isn=E2=80=99t the actual problem for an older running system generation t= o know which bootloder is currently in use? I think this can't be inferred = by the currently running system generation. It may happen, that you use a b= rand new bootloader which is not known by the older system generation you j= ust switched to. I think guix-the-package-manager is still the newest one even after selecti= ng an older system generation. So the "brand new bootloader" case should be fine. But the delete-generation case basically would have had to do the actual bo= otloader installation too. Like it is now, it totally has a huge problem. A possible way around having to know which bootloader is in use would be to= just always install the configurations for all the known bootloaders. > But still then, if you invoke a 'sudo -E guix system delete-generations' = or a 'sudo -E guix system reconfigure' I think you still use the very lates= t guix version that you 'guix pull'-ed last. Yes. > And that guix version should still know all brand new bootloader. The pro= blem may =E2=80=9Conly=E2=80=9D be to know for 'sudo -E guix system delete-= generations' which one to use. Yep. > But actually the bootloader-name field in /var/guix/profiles/system/param= eters can't tell either, as it must be an older bootloader than the brand n= ew one. Correct. > Maybe the information about the bootloader version in use needs to reside= with the installed bootloader somewhere below /boot/efi/=E2=80=A6? But thi= s may be impossible for the legacy grub-bootloader. That sounds like a huge can of worms to open. Better would be some kind of= bootloader detector (can package "os-prober" do it maybe?)--or better yet,= just also install the bootloader each time a system generation is deleted = and/or system in reconfigured. That was the original plan. --Sig_/Yd/Y.Ar=_/91LQW_.QAyPZA Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQEzBAEBCgAdFiEEds7GsXJ0tGXALbPZ5xo1VCwwuqUFAl7KebcACgkQ5xo1VCww uqUsvAgAlGyws4HsfWGihBuvDBRyJ0XlR22D1MQ6RxN9A2soIu6YiEldFXqItcBb mSeSL9qQ7RZ2BfQierpulYMjqgTIsuFoNsu8FdeGTKqmh4e7Cl5yeE3x7GvYLAYf DHv1ljnG1ri+9DA3zVyVd0XyMyq2tydPxywoggwGE9RUdRyJOvHU7DuesMKJPpiR SnQm+OwYCu//3IPDB6p3eAWO2xM0SRJaH+ffXgU6u3XrwXOYe926J+irtNgNOnw1 bgkglLLWyP8bv38VjOFnX3ymJfTa0O+FsPx5r4VmwF4j2WYwSQ+vP8l4Uydq2t5s +hzS0E0c57jCn7eV/LTceYHWIq3GWQ== =T7xj -----END PGP SIGNATURE----- --Sig_/Yd/Y.Ar=_/91LQW_.QAyPZA--