From unknown Sat Jun 14 03:48:47 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#60442 <60442@debbugs.gnu.org> To: bug#60442 <60442@debbugs.gnu.org> Subject: Status: [PATCH] bootloader: grub: Add support for root on lvm. Reply-To: bug#60442 <60442@debbugs.gnu.org> Date: Sat, 14 Jun 2025 10:48:47 +0000 retitle 60442 [PATCH] bootloader: grub: Add support for root on lvm. reassign 60442 guix-patches submitter 60442 Michael Rohleder severity 60442 normal tag 60442 patch thanks From debbugs-submit-bounces@debbugs.gnu.org Fri Dec 30 20:27:21 2022 Received: (at submit) by debbugs.gnu.org; 31 Dec 2022 01:27:21 +0000 Received: from localhost ([127.0.0.1]:36311 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pBQee-0001GR-Al for submit@debbugs.gnu.org; Fri, 30 Dec 2022 20:27:20 -0500 Received: from lists.gnu.org ([209.51.188.17]:43092) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pBQec-0001GJ-66 for submit@debbugs.gnu.org; Fri, 30 Dec 2022 20:27:18 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pBQeb-0007kY-4U for guix-patches@gnu.org; Fri, 30 Dec 2022 20:27:17 -0500 Received: from sxb1nlsmtp02.prod.sxb1.secureserver.net ([92.204.71.190]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pBQeY-0003wL-9x for guix-patches@gnu.org; Fri, 30 Dec 2022 20:27:16 -0500 Received: from 122.164.205.92.host.secureserver.net ([92.205.164.122]) by : HOSTING RELAY : with ESMTP id BQdTpVZeH3oQVBQdUpFyP5; Fri, 30 Dec 2022 18:26:08 -0700 X-SECURESERVER-ACCT: 92.205.164.122 x-originating-ip: 92.205.164.122 X-CMAE-Analysis: v=2.4 cv=SfYxNNdu c=1 sm=1 tr=0 ts=63af8fb0 a=B/z3iHJ5y0TSvJOmeNZOnw==:117 a=IkcTkHD0fZMA:10 a=sHyYjHe8cH0A:10 a=mDV3o1hIAAAA:8 a=TBl5w1EdAAAA:8 a=dPDPl_EnAAAA:8 a=AdZ5fGlyAAAA:8 a=pGLkceISAAAA:8 a=_he-KxU42j6O13qn8SUA:9 a=QEXdDO2ut3YA:10 a=_FVE-zBwftR9WsbkzFJk:22 a=5WwPNqJOUSiJ-goaxTcI:22 a=bd0dmHXOa7EyMKz6Wi46:22 a=KE2k9AvrBXY8Rl8PC8rS:22 Received: from [192.168.1.3] (helo=micha.rohleder.de) by 122.164.205.92.host.secureserver.net with esmtp (Exim 4.94.2) (envelope-from ) id 1pBQdT-006USN-37; Sat, 31 Dec 2022 02:26:07 +0100 From: Michael Rohleder To: guix-patches@gnu.org Subject: [PATCH] bootloader: grub: Add support for root on lvm. Date: Sat, 31 Dec 2022 02:25:11 +0100 Message-Id: <20221231012511.5031-1-mike@rohleder.de> X-Mailer: git-send-email 2.38.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-CMAE-Envelope: MS4xfHmEW3T7gXAStLVQ2Ghn4ASQPmGkYQV/fjEpF4illE787ZoL1+bx9glPh6IxuM958/YJTFR7ErG/8xPSAOf7P/QAHYyGadbc19qAO+2I++MoVO/qCaHr DbkfBysqdNkQQsbIxjGoe0Nnzr42Fyfn+662nkg8Yz9KR21Y0lEiPWH9r+RZlGoKhSFahNpmk0XfVD16G7z4+jk5UYsk3l4dBRGoHCCuv0k3XN8oU1xZxjMr da6p1J+SgGoSZQBzNGmKCQ== Received-SPF: permerror client-ip=92.204.71.190; envelope-from=mike@rohleder.de; helo=sxb1nlsmtp02.prod.sxb1.secureserver.net X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, T_SPF_PERMERROR=0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: submit Cc: Michael Rohleder X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) This fixes . * gnu/bootloader/grub.scm (install-grub) (install-grub-efi) (install-grub-efi-removable) (install-grub-efi32): Add setting GRUB_PRELOAD_MODULES to lvm. * gnu/tests/install.scm (test-lvm-root-os): New variable. --- gnu/bootloader/grub.scm | 9 +++++ gnu/tests/install.scm | 81 ++++++++++++++++++++++++++++++++++++++++- 2 files changed, 89 insertions(+), 1 deletion(-) diff --git a/gnu/bootloader/grub.scm b/gnu/bootloader/grub.scm index ecd44e7f3c..1e2d142452 100644 --- a/gnu/bootloader/grub.scm +++ b/gnu/bootloader/grub.scm @@ -9,6 +9,7 @@ ;;; Copyright © 2020 Stefan ;;; Copyright © 2022 Karl Hallsby ;;; Copyright © 2022 Denis 'GNUtoo' Carikli +;;; Copyright © 2022 Michael Rohleder ;;; ;;; This file is part of GNU Guix. ;;; @@ -557,6 +558,8 @@ (define install-grub ;; Tell 'grub-install' that there might be a LUKS-encrypted ;; /boot or root partition. (setenv "GRUB_ENABLE_CRYPTODISK" "y") + ;; Let us boot from lvm + (setenv "GRUB_PRELOAD_MODULES" "lvm") ;; Hide potentially confusing messages from the user, such as ;; "Installing for i386-pc platform." @@ -629,6 +632,8 @@ (define install-grub-efi ;; Tell 'grub-install' that there might be a LUKS-encrypted /boot or ;; root partition. (setenv "GRUB_ENABLE_CRYPTODISK" "y") + ;; Let us boot from lvm + (setenv "GRUB_PRELOAD_MODULES" "lvm") (invoke/quiet grub-install "--boot-directory" install-dir "--bootloader-id=Guix" "--efi-directory" target-esp))))) @@ -652,6 +657,8 @@ (define install-grub-efi-removable ;; Tell 'grub-install' that there might be a LUKS-encrypted /boot or ;; root partition. (setenv "GRUB_ENABLE_CRYPTODISK" "y") + ;; Let us boot from lvm + (setenv "GRUB_PRELOAD_MODULES" "lvm") (invoke/quiet grub-install "--boot-directory" install-dir "--removable" ;; "--no-nvram" @@ -675,6 +682,8 @@ (define install-grub-efi32 ;; Tell 'grub-install' that there might be a LUKS-encrypted /boot or ;; root partition. (setenv "GRUB_ENABLE_CRYPTODISK" "y") + ;; Let us boot from lvm + (setenv "GRUB_PRELOAD_MODULES" "lvm") (invoke/quiet grub-install "--boot-directory" install-dir "--bootloader-id=Guix" (cond ((target-x86?) "--target=i386-efi") diff --git a/gnu/tests/install.scm b/gnu/tests/install.scm index 4e0e274e66..f9d34c1e28 100644 --- a/gnu/tests/install.scm +++ b/gnu/tests/install.scm @@ -5,6 +5,7 @@ ;;; Copyright © 2020 Danny Milosavljevic ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen ;;; Copyright © 2020, 2021, 2022 Maxim Cournoyer +;;; Copyright © 2022 Michael Rohleder ;;; ;;; This file is part of GNU Guix. ;;; @@ -76,6 +77,7 @@ (define-module (gnu tests install) %test-jfs-root-os %test-f2fs-root-os %test-xfs-root-os + %test-lvm-root-os %test-lvm-separate-home-os %test-gui-installed-os @@ -831,7 +833,6 @@ (define %test-encrypted-root-os ;;; Separate /home on LVM ;;; -;; Since LVM support in guix currently doesn't allow root-on-LVM we use /home on LVM (define-os-with-source (%lvm-separate-home-os %lvm-separate-home-os-source) (use-modules (gnu) (gnu tests)) @@ -913,6 +914,84 @@ (define %test-lvm-separate-home-os `(,@command) "lvm-separate-home-os"))))) + +;;; +;;; LVM root device. +;;; + +(define-os-with-source (%lvm-root-os %lvm-root-os-source) + (use-modules (gnu) (gnu tests)) + + (operating-system + (host-name "root-os-on-lvm") + (timezone "Europe/Paris") + (locale "en_US.utf8") + + (bootloader (bootloader-configuration + (bootloader grub-bootloader) + (targets (list "/dev/vdb")))) + (kernel-arguments '("console=ttyS0")) + + (mapped-devices (list (mapped-device + (source "vg0") + (target "vg0-root") + (type lvm-device-mapping)))) + (file-systems (cons* (file-system + (device "/dev/mapper/vg0-root") + (mount-point "/") + (type "ext4") + (dependencies mapped-devices)) + %base-file-systems)) + (users %base-user-accounts) + (services (cons (service marionette-service-type + (marionette-configuration + (imported-modules '((gnu services herd) + (guix combinators))))) + %base-services)))) + +(define %lvm-root-os-installation-script + "\ +. /etc/profile +set -e -x +guix --version + +export GUIX_BUILD_OPTIONS=--no-grafts +parted --script /dev/vdb mklabel gpt \\ + mkpart primary ext2 1M 3M \\ + mkpart primary 3M 1.7G \\ + set 1 boot on \\ + set 1 bios_grub on +pvcreate /dev/vdb2 +vgcreate vg0 /dev/vdb2 +lvcreate -l 100%FREE -n root vg0 +vgchange -ay +mkfs.ext4 -L root-fs /dev/mapper/vg0-root +mount /dev/mapper/vg0-root /mnt +herd start cow-store /mnt +mkdir /mnt/etc +cp /etc/target-config.scm /mnt/etc/config.scm +guix system init /mnt/etc/config.scm /mnt --no-substitutes +sync +reboot\n") + +(define %test-lvm-root-os + (system-test + (name "lvm-root-os") + (description + "Test functionality of an OS installed with a LVM / partition") + (value + (mlet* %store-monad ((image (run-install %lvm-root-os + %lvm-root-os-source + #:script + %lvm-root-os-installation-script + #:packages (list lvm2-static))) + (command (qemu-command* image + #:memory-size 512))) + (run-basic-test %lvm-root-os + `(,@command) "lvm-root-os"))))) + + + ;;; ;;; LUKS-encrypted /home, unencrypted root. ;;; -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 21 13:39:50 2023 Received: (at 60442) by debbugs.gnu.org; 21 Mar 2023 17:39:50 +0000 Received: from localhost ([127.0.0.1]:60464 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pefxe-0000uE-5u for submit@debbugs.gnu.org; Tue, 21 Mar 2023 13:39:50 -0400 Received: from mail-qv1-f41.google.com ([209.85.219.41]:33331) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pefxb-0000tw-0V for 60442@debbugs.gnu.org; Tue, 21 Mar 2023 13:39:48 -0400 Received: by mail-qv1-f41.google.com with SMTP id m6so10382376qvq.0 for <60442@debbugs.gnu.org>; Tue, 21 Mar 2023 10:39:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1679420381; h=content-transfer-encoding:mime-version:message-id:date:user-agent :references:in-reply-to:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Rzff/jKHK/WloBA7o/mjRsqb87Zu/66ZETJnaaOl4QQ=; b=oREhJAZNPzob332U/YWl5Ih66uuXe+wHPA02cJwxZIp+ypOk8+xiRtU+vjFGZIW1g4 YyvWFQejfdUv+r3sgHDiNy9Qv9U91PJz0AO7frHumko1/ke91O9VvDAssyZeuBqcz450 OLUYZF12M3v1ZDxC0ha65FbSCpFJztgtWS1Y9akV186UrcPRi+/yLi5OQSJEcXQ3MIID kTPozIWnKKxuPDN8kWUdw9VbPef/kvUZ7bOmsXQIqfm0xcOh/LGf9YqAay+1hgFJWy/F DdabYbQZu0fxNDjXp/0u0hGD1o67RY9qWijaaBo6pZwTlbqfOx9dZnpREuPOt5MEa+/A Tq8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679420381; h=content-transfer-encoding:mime-version:message-id:date:user-agent :references:in-reply-to:subject:cc:to:from:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=Rzff/jKHK/WloBA7o/mjRsqb87Zu/66ZETJnaaOl4QQ=; b=PvA0jfCIEOEjHKRAmYZHE3eHvbFqcTTPNL+S4/7hJBFZgXfC6TaduIsJTt9oEogcSJ GGBbhfbJGFmGpY347GYabDEwXuhVSvrec8uL9I+qIwcKL4lR+poeFQoXyH/EVcam2KD7 24IcqZzJ3naQ0MYHcFmx8QQvGBe0RbDBRG9h9gsw/TRIt7635R6hVb5wSuLqEWHEWw5y gKVt+347Q+OTl1pavQzX55+FTneg868J4VhX6QZNUaFSsAmlCHdyb7UiLUgdL3WcX4VC nHQYq5bIDv8Lc89OSq/6R1XuWTCd0rO2nUnYwfRmJQtES0/CghUrBK5M7ND4e59aG41P 7b7A== X-Gm-Message-State: AO0yUKUEjrVfXmMiArsEp8Rqgm/LgUMesFisXBVVT9zvN1DY+PBsSHk9 aSX/27MmHRRJX7wbQXg0yw6DRwA9fR2c6g== X-Google-Smtp-Source: AK7set/a1qvTdV5kYrEfefBxXdlTpQuL5HJ3P0jqp2/qGby9lpLF6GLIHqM4gXhZBjrHnaJfcgdr4g== X-Received: by 2002:a05:6214:e4c:b0:56e:a3a2:1a1c with SMTP id o12-20020a0562140e4c00b0056ea3a21a1cmr656301qvc.33.1679420380949; Tue, 21 Mar 2023 10:39:40 -0700 (PDT) Received: from hurd (dsl-10-130-195.b2b2c.ca. [72.10.130.195]) by smtp.gmail.com with ESMTPSA id 11-20020a37060b000000b0071d0f1d01easm3610166qkg.57.2023.03.21.10.39.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 Mar 2023 10:39:40 -0700 (PDT) From: Maxim Cournoyer To: Michael Rohleder Subject: Re: bug#60442: [PATCH] bootloader: grub: Add support for root on lvm. In-Reply-To: <20221231012511.5031-1-mike@rohleder.de> (Michael Rohleder's message of "Sat, 31 Dec 2022 02:25:11 +0100") References: <20221231012511.5031-1-mike@rohleder.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) Date: Tue, 21 Mar 2023 13:39:38 -0400 Message-ID: <87pm92ngv9.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 60442 Cc: 60442@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi Michael, Michael Rohleder writes: > This fixes . > > * gnu/bootloader/grub.scm (install-grub) > (install-grub-efi) > (install-grub-efi-removable) > (install-grub-efi32): Add setting GRUB_PRELOAD_MODULES to lvm. > * gnu/tests/install.scm (test-lvm-root-os): New variable. > --- > gnu/bootloader/grub.scm | 9 +++++ > gnu/tests/install.scm | 81 ++++++++++++++++++++++++++++++++++++++++- > 2 files changed, 89 insertions(+), 1 deletion(-) > > diff --git a/gnu/bootloader/grub.scm b/gnu/bootloader/grub.scm > index ecd44e7f3c..1e2d142452 100644 > --- a/gnu/bootloader/grub.scm > +++ b/gnu/bootloader/grub.scm > @@ -9,6 +9,7 @@ > ;;; Copyright =C2=A9 2020 Stefan > ;;; Copyright =C2=A9 2022 Karl Hallsby > ;;; Copyright =C2=A9 2022 Denis 'GNUtoo' Carikli > +;;; Copyright =C2=A9 2022 Michael Rohleder > ;;; > ;;; This file is part of GNU Guix. > ;;; > @@ -557,6 +558,8 @@ (define install-grub > ;; Tell 'grub-install' that there might be a LUKS-encrypted > ;; /boot or root partition. > (setenv "GRUB_ENABLE_CRYPTODISK" "y") > + ;; Let us boot from lvm > + (setenv "GRUB_PRELOAD_MODULES" "lvm") >=20=20 > ;; Hide potentially confusing messages from the user, such= as > ;; "Installing for i386-pc platform." > @@ -629,6 +632,8 @@ (define install-grub-efi > ;; Tell 'grub-install' that there might be a LUKS-encrypted /b= oot or > ;; root partition. > (setenv "GRUB_ENABLE_CRYPTODISK" "y") > + ;; Let us boot from lvm > + (setenv "GRUB_PRELOAD_MODULES" "lvm") > (invoke/quiet grub-install "--boot-directory" install-dir > "--bootloader-id=3DGuix" > "--efi-directory" target-esp))))) > @@ -652,6 +657,8 @@ (define install-grub-efi-removable > ;; Tell 'grub-install' that there might be a LUKS-encrypted /b= oot or > ;; root partition. > (setenv "GRUB_ENABLE_CRYPTODISK" "y") > + ;; Let us boot from lvm > + (setenv "GRUB_PRELOAD_MODULES" "lvm") > (invoke/quiet grub-install "--boot-directory" install-dir > "--removable" > ;; "--no-nvram" > @@ -675,6 +682,8 @@ (define install-grub-efi32 > ;; Tell 'grub-install' that there might be a LUKS-encrypted /b= oot or > ;; root partition. > (setenv "GRUB_ENABLE_CRYPTODISK" "y") > + ;; Let us boot from lvm > + (setenv "GRUB_PRELOAD_MODULES" "lvm") > (invoke/quiet grub-install "--boot-directory" install-dir > "--bootloader-id=3DGuix" > (cond ((target-x86?) "--target=3Di386-efi") > diff --git a/gnu/tests/install.scm b/gnu/tests/install.scm > index 4e0e274e66..f9d34c1e28 100644 > --- a/gnu/tests/install.scm > +++ b/gnu/tests/install.scm > @@ -5,6 +5,7 @@ > ;;; Copyright =C2=A9 2020 Danny Milosavljevic > ;;; Copyright =C2=A9 2020 Jan (janneke) Nieuwenhuizen > ;;; Copyright =C2=A9 2020, 2021, 2022 Maxim Cournoyer > +;;; Copyright =C2=A9 2022 Michael Rohleder > ;;; > ;;; This file is part of GNU Guix. > ;;; > @@ -76,6 +77,7 @@ (define-module (gnu tests install) > %test-jfs-root-os > %test-f2fs-root-os > %test-xfs-root-os > + %test-lvm-root-os > %test-lvm-separate-home-os >=20=20 > %test-gui-installed-os > @@ -831,7 +833,6 @@ (define %test-encrypted-root-os > ;;; Separate /home on LVM > ;;; >=20=20 > -;; Since LVM support in guix currently doesn't allow root-on-LVM we use = /home on LVM > (define-os-with-source (%lvm-separate-home-os %lvm-separate-home-os-sour= ce) > (use-modules (gnu) (gnu tests)) >=20=20 > @@ -913,6 +914,84 @@ (define %test-lvm-separate-home-os > `(,@command) "lvm-separate-home-os"))))) >=20=20 > > + > +;;; > +;;; LVM root device. > +;;; > + > +(define-os-with-source (%lvm-root-os %lvm-root-os-source) > + (use-modules (gnu) (gnu tests)) > + > + (operating-system > + (host-name "root-os-on-lvm") > + (timezone "Europe/Paris") > + (locale "en_US.utf8") > + > + (bootloader (bootloader-configuration > + (bootloader grub-bootloader) > + (targets (list "/dev/vdb")))) > + (kernel-arguments '("console=3DttyS0")) > + > + (mapped-devices (list (mapped-device > + (source "vg0") > + (target "vg0-root") > + (type lvm-device-mapping)))) > + (file-systems (cons* (file-system > + (device "/dev/mapper/vg0-root") > + (mount-point "/") > + (type "ext4") > + (dependencies mapped-devices)) > + %base-file-systems)) > + (users %base-user-accounts) > + (services (cons (service marionette-service-type > + (marionette-configuration > + (imported-modules '((gnu services herd) > + (guix combinators))))) > + %base-services)))) > + > +(define %lvm-root-os-installation-script > + "\ > +. /etc/profile > +set -e -x > +guix --version > + > +export GUIX_BUILD_OPTIONS=3D--no-grafts > +parted --script /dev/vdb mklabel gpt \\ > + mkpart primary ext2 1M 3M \\ > + mkpart primary 3M 1.7G \\ > + set 1 boot on \\ > + set 1 bios_grub on > +pvcreate /dev/vdb2 > +vgcreate vg0 /dev/vdb2 > +lvcreate -l 100%FREE -n root vg0 > +vgchange -ay > +mkfs.ext4 -L root-fs /dev/mapper/vg0-root > +mount /dev/mapper/vg0-root /mnt > +herd start cow-store /mnt > +mkdir /mnt/etc > +cp /etc/target-config.scm /mnt/etc/config.scm > +guix system init /mnt/etc/config.scm /mnt --no-substitutes > +sync > +reboot\n") > + > +(define %test-lvm-root-os > + (system-test > + (name "lvm-root-os") > + (description > + "Test functionality of an OS installed with a LVM / partition") > + (value > + (mlet* %store-monad ((image (run-install %lvm-root-os > + %lvm-root-os-source > + #:script > + %lvm-root-os-installation= -script > + #:packages (list lvm2-sta= tic))) > + (command (qemu-command* image > + #:memory-size 512))) > + (run-basic-test %lvm-root-os > + `(,@command) "lvm-root-os"))))) > + > + > + Thanks for this patch. I've applied the change locally, and wanted to see the test fail first, so I've reverted the following: --8<---------------cut here---------------start------------->8--- Unstaged changes (1) modified gnu/bootloader/grub.scm @@ -632,8 +632,6 @@ (define install-grub-efi ;; Tell 'grub-install' that there might be a LUKS-encrypted /boo= t or ;; root partition. (setenv "GRUB_ENABLE_CRYPTODISK" "y") - ;; Let us boot from lvm - (setenv "GRUB_PRELOAD_MODULES" "lvm") (invoke/quiet grub-install "--boot-directory" install-dir "--bootloader-id=3DGuix" "--efi-directory" target-esp))))) @@ -657,8 +655,6 @@ (define install-grub-efi-removable ;; Tell 'grub-install' that there might be a LUKS-encrypted /boo= t or ;; root partition. (setenv "GRUB_ENABLE_CRYPTODISK" "y") - ;; Let us boot from lvm - (setenv "GRUB_PRELOAD_MODULES" "lvm") (invoke/quiet grub-install "--boot-directory" install-dir "--removable" ;; "--no-nvram" @@ -682,8 +678,6 @@ (define install-grub-efi32 ;; Tell 'grub-install' that there might be a LUKS-encrypted /boo= t or ;; root partition. (setenv "GRUB_ENABLE_CRYPTODISK" "y") - ;; Let us boot from lvm - (setenv "GRUB_PRELOAD_MODULES" "lvm") (invoke/quiet grub-install "--boot-directory" install-dir "--bootloader-id=3DGuix" (cond ((target-x86?) "--target=3Di386-efi") --8<---------------cut here---------------end--------------->8--- And to my surprise 'make check-system TESTS=3Dlvm-root-os' passed: --8<---------------cut here---------------start------------->8--- %%%% Starting test basic (Writing full log to "/gnu/store/m3rifzddpnc4x47r= 7nhfjkms97nzrc69-lvm-root-os/b) marionette is ready PASS: uname PASS: shepherd socket ready PASS: stdin is /dev/null PASS: shell and user commands PASS: special files PASS: accounts ;;; (services (guix-daemon syslogd mcron console-font-tty3 file-system-/dev= /shm console-font-tty5 file-sy) PASS: shepherd services PASS: libc honors /etc/localtime PASS: /var/log/messages is not world-readable PASS: homes PASS: skeletons in home directories PASS: permissions on /root PASS: ownership and permissions of /var/empty PASS: no extra home directories PASS: login on tty1 PASS: getlogin on tty1 PASS: utmpx entry PASS: wtmp entry PASS: host name resolution PASS: nscd configuration action PASS: nscd invalidate action SKIP: nscd invalidate action, wrong table PASS: host not found PASS: locale PASS: /run/current-system is a GC root PASS: /var/guix/gcroots/profiles is a valid symlink PASS: guix-daemon set-http-proxy action PASS: guix-daemon set-http-proxy action, clear PASS: screendump PASS: screen text # of expected passes 29 # of skipped tests 1 Some deprecated features have been used. Set the environment variable GUILE_WARN_DEPRECATED to "detailed" and rerun the program to get more information. Set it to "no" to suppress this message. successfully built /gnu/store/69naxa7pcjlkn25xz033964z3vgp5c9d-lvm-root-os.= drv /gnu/store/m3rifzddpnc4x47r7nhfjkms97nzrc69-lvm-root-os --8<---------------cut here---------------end--------------->8--- Are you sure this change is really needed? Otherwise why would the test pass even without the change? --=20 Thanks, Maxim From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 22 23:19:29 2023 Received: (at 60442) by debbugs.gnu.org; 23 Mar 2023 03:19:29 +0000 Received: from localhost ([127.0.0.1]:37018 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pfBU9-00064b-DS for submit@debbugs.gnu.org; Wed, 22 Mar 2023 23:19:29 -0400 Received: from sxb1nlsmtp03.prod.sxb1.secureserver.net ([92.204.71.211]:57550) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pfBU6-00064M-Id for 60442@debbugs.gnu.org; Wed, 22 Mar 2023 23:19:27 -0400 Received: from 122.164.205.92.host.secureserver.net ([92.205.164.122]) by : HOSTING RELAY : with ESMTP id fBSzp2Dybe4s5fBT0pheqj; Wed, 22 Mar 2023 20:18:18 -0700 X-SECURESERVER-ACCT: 92.205.164.122 x-originating-ip: 92.205.164.122 X-CMAE-Analysis: v=2.4 cv=I+ijBvsg c=1 sm=1 tr=0 ts=641bc4fa a=B/z3iHJ5y0TSvJOmeNZOnw==:117 a=sWBCwOrcjvIDNuCI:21 a=k__wU0fu6RkA:10 a=pGLkceISAAAA:8 a=uJOnGUVS9WCRjOxFWKgA:9 a=kXziqvYyf-5JkjrIrpgA:9 a=FfaGCDsud1wA:10 a=bO89PWORXKzKR_uMiO3p:22 Received: from [192.168.1.3] (helo=micha) by 122.164.205.92.host.secureserver.net with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1pfBS4-00HHk9-7h; Thu, 23 Mar 2023 04:18:17 +0100 From: Michael Rohleder To: Maxim Cournoyer Subject: Re: bug#60442: [PATCH] bootloader: grub: Add support for root on lvm. In-Reply-To: <87pm92ngv9.fsf@gmail.com> (Maxim Cournoyer's message of "Tue, 21 Mar 2023 13:39:38 -0400") References: <20221231012511.5031-1-mike@rohleder.de> <87pm92ngv9.fsf@gmail.com> Date: Thu, 23 Mar 2023 04:17:14 +0100 Message-ID: <87lejokvgl.fsf@rohleder.de> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" X-CMAE-Envelope: MS4xfHiFEaUkhFBirbpAJe84ST21t9Lywvy9DoCgujxRq+BT7zxTXb3ghG8oMYyaOFZRWhEpFQsiY6MawpZeCF+mXsoZffCM/R/0avZovllTHwoCUyg+Dj9/ fJLS42xV03hswlU+iEXr8EZREr0SCMl93GTsjdOjRUenFic/fTkaDgRZ6IEj7ZllL5ppceSQAgUnQKJB0ZdyHYeEqCsw2r6mgzHtf7UqNmxDWAzHGqNh3VX5 9GEuHaAhJI2yzyXUM1meVw== X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 60442 Cc: 60442@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Hi Maxim, Maxim Cournoyer writes: > Are you sure this change is really needed? Otherwise why would the test > pass even without the change? No, after reading #62140, I'm not sure. That means the test is also wrong, which I don't understand. =2D-=20 All generalizations are bad. --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQFFBAEBCAAvFiEEdV4t5dDVhcUueCgwfHr/vv7yyyUFAmQbxLoRHG1pa2VAcm9o bGVkZXIuZGUACgkQfHr/vv7yyyU0wAf+JSGBWvArGF2TK5IHv49mlbqUQCJ6nu0p XpZQte3PZA9rxnbNphJ1uhiYCYL1trZ8+ZsIzdf8rFgV4PnsF0WlrVeKfUWwl0QG 405xtvejPkHzqIfsrlPsWuFi17mKffLzexOyhWb9XlwP4z8RibXsow9iNJvCYrGN drfeUiHrXpPQHCSQ9U4tFiOzwIJtOVd+F8rQiVgbFC39hQkkMx6/wyZ1MxmcVt9a Ajrb4YAfkjPfLXErPvhDU/oiVSY/iHIcbvHUnmLuh0vVNmHiRo9dpmIkDGWiW5sN NZUxWjktmYIC86IbAfmPkMVZ8d9NrCTLiDrPVBf4OYV/Mpxh7YuRvQ== =psyh -----END PGP SIGNATURE----- --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Wed May 17 16:42:40 2023 Received: (at 60442-done) by debbugs.gnu.org; 17 May 2023 20:42:40 +0000 Received: from localhost ([127.0.0.1]:51184 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pzNyq-0000HM-IZ for submit@debbugs.gnu.org; Wed, 17 May 2023 16:42:40 -0400 Received: from jpoiret.xyz ([206.189.101.64]:47240) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pzNyo-0000HD-0U for 60442-done@debbugs.gnu.org; Wed, 17 May 2023 16:42:38 -0400 Received: from authenticated-user (jpoiret.xyz [206.189.101.64]) by jpoiret.xyz (Postfix) with ESMTPA id 3EF9D184F2B; Wed, 17 May 2023 20:42:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jpoiret.xyz; s=dkim; t=1684356156; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=09sFzQvuro6qm/IPu1jJPeWH4yZvwB9qPTZfxbQqVBU=; b=Afc21SyNzclKF3IpffBFgAAeSMtNM4bUbWJ6u47kBjb847rvA/xoC7gCeTwH8GeEQdwwZQ cdGL+eeDDxT2KTyd/yhzw7o3ys9uhzG026RfIeG/WsHmcvtgu5Eqv1j03lttV0QNg9Gf4I bzBAjnP/+6d2vweb3NN6PwTh0RhaAdrPEs+ZAoFOspVzdam9W+q2fB8vatKzowSJlXoMXq nHggQV1bswLccIEsKossI++P7XXkGAYI6A7yBDuN8fcsNRVV8ApdO1XwMwM3KrtNwVepFQ y4o3nqdAVEvotLhfUd2lFzAe0ViOMM+4TVYeqEPBPiD/9GIscMHmA28gQcTurw== From: Josselin Poiret To: Michael Rohleder , Maxim Cournoyer Subject: Re: [bug#60442] [PATCH] bootloader: grub: Add support for root on lvm. In-Reply-To: <87lejokvgl.fsf@rohleder.de> References: <20221231012511.5031-1-mike@rohleder.de> <87pm92ngv9.fsf@gmail.com> <87lejokvgl.fsf@rohleder.de> Date: Wed, 17 May 2023 22:42:33 +0200 Message-ID: <87pm6y1yh2.fsf@jpoiret.xyz> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spamd-Bar: / Authentication-Results: jpoiret.xyz; auth=pass smtp.auth=jpoiret@jpoiret.xyz smtp.mailfrom=dev@jpoiret.xyz X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 60442-done Cc: 60442-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.0 (/) --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Hi, Michael Rohleder writes: > No, after reading #62140, I'm not sure. > That means the test is also wrong, which I don't understand. I don't have an LVM system to test on, but I'm pretty sure we just need to add the corresponding insmod when an LVM mapping is used. In the meantime, closing this bug, please refer to #62140 for more discussion. Best, =2D-=20 Josselin Poiret --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQHEBAEBCgAuFiEEOSSM2EHGPMM23K8vUF5AuRYXGooFAmRlPDkQHGRldkBqcG9p cmV0Lnh5egAKCRBQXkC5FhcaivwaDACbNyDrA5JErRsy3MeOpLN1MQGwIAtPLHim ronkVMKlFwxhjcFpT2WpIu3UNtPfeSr0GZE9+QjE2bRrY13LsfYso3obO38DoLd6 UXhh1HFp+Zm2OM/iDX2f+QiSIjHsiKIUiXOEjYz7FTsJqS3PvKawmbUg2/mv5MNO QEBTQWrU+4GpOtK+kSwghPiUk9G4GhM/1OdWtYU0Aa3SsJarepL8q22hDGibKGR7 /8UsWo4DERyZxbMTFdRRwUGA4fU9IjVBJXRRISRWU/fNyG5HeNmgMgiocqU7QPe9 FwQP+JQDAwV81CqU/35VWFZcCz+piKO+bqsPlqzv3ZecRfLEzppWjxPxD3GBuvIs jCoZRYj2qy6Jc/KFFZlJz44cqcxRLpa/vHou4bUqOtxvCNJCiosBRZdMh7yhpt/8 jTMKva3isRmkir9tq9Dy2r+QQQomWB25QSnXyqdtOCTo4BfRZUgxv2NFySmJFlpR j1fYFTPWcGAXjW/0+7kYezEjKqCeykg= =8W89 -----END PGP SIGNATURE----- --=-=-=-- From unknown Sat Jun 14 03:48:47 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 15 Jun 2023 11:24:08 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator