From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id I6WPC9GKFmHhZAAAgWs5BA (envelope-from ) for ; Fri, 13 Aug 2021 17:08:01 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id KK2/BtGKFmE5NQAAbx9fmQ (envelope-from ) for ; Fri, 13 Aug 2021 15:08:01 +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 637D3E3B1 for ; Fri, 13 Aug 2021 17:08:00 +0200 (CEST) Received: from localhost ([::1]:35160 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mEYmt-0007QL-5O for larch@yhetil.org; Fri, 13 Aug 2021 11:07:59 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40110) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mEYl0-0003Ru-Qi for bug-guix@gnu.org; Fri, 13 Aug 2021 11:06:04 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:59598) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mEYl0-000449-Jn for bug-guix@gnu.org; Fri, 13 Aug 2021 11:06:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mEYl0-00050y-9y for bug-guix@gnu.org; Fri, 13 Aug 2021 11:06:02 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#40999: GRUB prevents booting a degraded RAID1 array atop LUKS Resent-From: Giovanni Biscuolo Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Fri, 13 Aug 2021 15:06:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 40999 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Maxim Cournoyer Received: via spool by 40999-submit@debbugs.gnu.org id=B40999.162886715319262 (code B ref 40999); Fri, 13 Aug 2021 15:06:02 +0000 Received: (at 40999) by debbugs.gnu.org; 13 Aug 2021 15:05:53 +0000 Received: from localhost ([127.0.0.1]:42911 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mEYkn-00050Y-Kj for submit@debbugs.gnu.org; Fri, 13 Aug 2021 11:05:53 -0400 Received: from ns13.heimat.it ([46.4.214.66]:40010) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mEYki-00050H-FS for 40999@debbugs.gnu.org; Fri, 13 Aug 2021 11:05:48 -0400 Received: from localhost (ip6-localhost [127.0.0.1]) by ns13.heimat.it (Postfix) with ESMTP id C72753021BA; Fri, 13 Aug 2021 15:05:37 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at ns13.heimat.it Received: from ns13.heimat.it ([127.0.0.1]) by localhost (ns13.heimat.it [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id cSAgY-wU3cn2; Fri, 13 Aug 2021 15:05:14 +0000 (UTC) Received: from bourrache.mug.xelera.it (unknown [93.56.171.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by ns13.heimat.it (Postfix) with ESMTPSA id 00C193021B8; Fri, 13 Aug 2021 15:05:13 +0000 (UTC) Received: from roquette.mug.biscuolo.net (roquette [10.38.2.14]) by bourrache.mug.xelera.it (Postfix) with SMTP id 866EB11D0ABE; Fri, 13 Aug 2021 17:05:13 +0200 (CEST) Received: (nullmailer pid 19818 invoked by uid 1000); Fri, 13 Aug 2021 15:05:13 -0000 From: Giovanni Biscuolo In-Reply-To: <87fsvfz9eb.fsf@gmail.com> Organization: Xelera.eu References: <87o8r7kbbz.fsf@hurd.i-did-not-set--mail-host-address--so-tickle-me> <874kc14zd9.fsf@gmail.com> <87mtpof3bk.fsf@xelera.eu> <87fsvfz9eb.fsf@gmail.com> Date: Fri, 13 Aug 2021 17:05:12 +0200 Message-ID: <877dgpfkrb.fsf@xelera.eu> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: 40999@debbugs.gnu.org Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: "bug-Guix" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1628867280; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post; bh=FsatysRcL1zkLFr3W64tPx6517VNcpOKv+KPw1sv7xk=; b=LEbXOA2/AT5Nh64Nwnhm1ggBbH9wEc4zpLh6yFDzJ8RxdS2EokQKwykS3l6umK7RtiZvcV Y5a43Z/NI2eyU0NzgPPi8j1C6uJQEeQUfdaY3neFRnp/y0dWdK2+S+Bco1q2/Vy2/y2cTw VeVbS30TjF+pwLo/ANguMsfcalduDrEQew4xcGdU3N4ufGgSMbLCyvMlUp+GSl9cI0rcB/ TEXPUmOYRotVPy8hIuSGUFH0xG8I67OU/74fOLqgItI9t7N0llqF2hJ7kuVSKgeIlX0lVD XRhepAepp8P+WaEhRATvCkJy6EKSY8LbHvuvA3AEIBP6fY5ZdYCud/uKQ5qzeg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1628867280; a=rsa-sha256; cv=none; b=JRAWJ21VGIRl5kcLOlIww8AOMFkdIQecQ6ezN3iXHHUdLLkYxddl9mspwmzs0Srg7vCsBC Q9E9e4LIcHYdEciELzLyolvBqkdDYi0oNj1oar+htDYXoLXRsNOiSVp2R0xx8r2ZpPvG6Q Tc5sZnaUqzgwVIo6u6GlCj2Y5PiIDGpW4AAoNNiIh5SqkTtCuGh4iKVecDedq2rrR76d/f WCsoTWw0aYxDI/NikgM+HTDKVoDKFjw2CwehdlUNO7J0TgaDPpv60AxNWdqsuLzzfLyBOq 6tvAJXqDbTSBulTWlEaaEYs+Ymp6ZMwV5us7+mV6no9K3h54LWrXI9yZg909sg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Migadu-Spam-Score: -4.51 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Migadu-Queue-Id: 637D3E3B1 X-Spam-Score: -4.51 X-Migadu-Scanner: scn1.migadu.com X-TUID: uB6sm6ftUGgj --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi Maxim, I'd "debug" the issue trying to compare my Debian system config with yours since I'm also using a BTRFS RAID1 filesystem on LUKS. I've still not unplugged one of the two disks on mine to simulate a drive failure, Soon=E2=84=A2 I'd like to test this condition... but it's a busy machine so I don't know when. Maxim Cournoyer writes: [...] >>> Ideally, GRUB (or is it our boot script?) >> >> Since the end result is your system entered "grub rescue" mode AFAIU >> it's a GRUB issue > > Yeah, it looks like it. The grub.cfg file only has basic things in it, > nothing that could explain the failure. Please could you also provide the result of "lsblk -f"? This is (part of) my disks layout: =2D-8<---------------cut here---------------start------------->8--- sdc=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20 =E2=94=9C=E2=94=80sdc1=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20 =E2=94=9C=E2=94=80sdc2 vfat F6D8-67E3 = 470.8M 1% /boot/efi =E2=94=9C=E2=94=80sdc3 crypto_L e554b806-19ac-48b2-b521-b4= e89839a756=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 =E2=94=82 =E2=94=94=E2=94=80crypt_swap01 =E2=94=82 swap a43ce70c-dd35-47d8-a2ef-ef9d3c6d08= 85 [SWAP] =E2=94=94=E2=94=80sdc4 crypto_L 820bfdf7-46f7-46f5-8536-7e= 1b0f04e70e=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 =E2=94=94=E2=94=80crypt_btrfs01_03 btrfs btrfs_pool01 82afe97a-bb97-4b3d-90cb-93a058185b97=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20 sdd=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20 =E2=94=9C=E2=94=80sdd1=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20 =E2=94=9C=E2=94=80sdd2=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20 =E2=94=9C=E2=94=80sdd3 crypto_L 960aa919-182b-4604-a8be-84= 77c86386cc=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 =E2=94=82 =E2=94=94=E2=94=80crypt_swap02 =E2=94=82 swap 3f8f6974-05a9-4047-993a-c4ccb27eaa= 1d [SWAP] =E2=94=94=E2=94=80sdd4 crypto_L c590c62e-6ac8-418c-9ea7-7a= e9c79058c8=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 =E2=94=94=E2=94=80crypt_btrfs01_04 btrfs btrfs_pool01 82afe97a-bb97-4b3d-90cb-93a058185b97 802.= 3G 57% /mnt/btrfs =2D-8<---------------cut here---------------end--------------->8--- btrfs_pool01 is my BTRFS RAID1 filesystem, it includes /boot and / (root) and is on two ancrypted LUKS partitions, as you can see. Also, please what's your grub.cfg? This is the config of a menuentry of mine: =2D-8<---------------cut here---------------start------------->8--- menuentry 'Debian GNU/Linux' --class debian --class gnu-linux --class gnu -= -class os $menuentry_id_option 'gnulinux-simple-82afe97a-bb97-4b3d-90cb-93a= 058185b97' { load_video insmod gzio if [ x$grub_platform =3D xxen ]; then insmod xzio; insmod lzopio; fi insmod part_gpt insmod cryptodisk insmod luks insmod gcry_rijndael insmod gcry_rijndael insmod gcry_sha256 insmod btrfs cryptomount -u c590c62e6ac8418c9ea77ae9c79058c8 set root=3D'cryptouuid/c590c62e6ac8418c9ea77ae9c79058c8' if [ x$feature_platform_search_hint =3D xy ]; then search --no-floppy --fs-uuid --set=3Droot --hint=3D'cryptouuid/c590c62e6= ac8418c9ea77ae9c79058c8' 82afe97a-bb97-4b3d-90cb-93a058185b97 else search --no-floppy --fs-uuid --set=3Droot 82afe97a-bb97-4b3d-90cb-93a058= 185b97 fi echo 'Loading Linux 5.10.0-0.bpo.3-amd64 ...' linux /debian_root/boot/vmlinuz-5.10.0-0.bpo.3-amd64 root=3DUUID=3D82afe97= a-bb97-4b3d-90cb-93a058185b97 ro rootflags=3Dsubvol=3Ddebian_root ip=3D10.3= 8.2.2::10.38.2.1:255.255.255.0:anemone:eth0:none quiet echo 'Loading initial ramdisk ...' initrd /debian_root/boot/initrd.img-5.10.0-0.bpo.3-amd64 } =2D-8<---------------cut here---------------end--------------->8--- AFAIU this code (from the snippet above): =2D-8<---------------cut here---------------start------------->8--- if [ x$feature_platform_search_hint =3D xy ]; then search --no-floppy --fs-uuid --set=3Droot --hint=3D'cryptouuid/c590c62e6= ac8418c9ea77ae9c79058c8' 82afe97a-bb97-4b3d-90cb-93a058185b97 else search --no-floppy --fs-uuid --set=3Droot 82afe97a-bb97-4b3d-90cb-93a058= 185b97 fi =2D-8<---------------cut here---------------end--------------->8--- sets [1] the root GRUB env variable to the first found device containing the UUID 82afe97a-bb97-4b3d-90cb-93a058185b97, that is the UUID of my BTRFS filesystem AFAIU (but still not tested) this means that if the device with UUID c590c62[...] is missing the search ensures that GRUB will find the next device containing the BTRFS filesystem identified by UUID 82afe97a[...] WDYT? [1] https://www.gnu.org/software/grub/manual/grub/grub.html#search [...] >> Can you please provide the output of the "ls" command and the "set" >> command from the grub rescue shell? > > I'll post after rebooting. OK thanks. >> Also, please what is your /proc/cmdline (when Linux correcly boots)? > > --8<---------------cut here---------------start------------->8--- > BOOT_IMAGE=3D/@root/gnu/store/1c0dkkkv5vdnyp73gvcl9k1kym5jjm54-linux-libr= e-5.13.8/bzImage > --root=3D/dev/mapper/cryptroot > --system=3D/gnu/store/815481yf1kfacwgkh4aa11rlb3lm6gvi-system > --load=3D/gnu/store/815481yf1kfacwgkh4aa11rlb3lm6gvi-system/boot quiet > snd_hda_intel.dmic_detect=3D0 modprobe.blacklist=3Drtl8187 > --8<---------------cut here---------------end--------------->8--- This is mine (derived from the GRUB menu entry shown above): =2D-8<---------------cut here---------------start------------->8--- BOOT_IMAGE=3D/debian_root/boot/vmlinuz-5.10.0-0.bpo.3-amd64 root=3DUUID=3D8= 2afe97a-bb97-4b3d-90cb-93a058185b97 ro rootflags=3Dsubvol=3Ddebian_root ip= =3D10.38.2.2::10.38.2.1:255.255.255.0:anemone:eth0:none quiet =2D-8<---------------cut here---------------end--------------->8--- AFAIU using "root=3DUUID=3D..." is more robust than using the (possibly missing) device mapper path. [...] Hope this helps. Best regards, Gio' =2D-=20 Giovanni Biscuolo Xelera IT Infrastructures --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQJABAEBCgAqFiEERcxjuFJYydVfNLI5030Op87MORIFAmEWiigMHGdAeGVsZXJh LmV1AAoJENN9DqfOzDkSY8YP/iB/GPK1aMMIGc6ypasdMXP136TYlUke51SLjIQ/ rhhYnqy4XYYvK0ajM5IwAmbljZTeFkMuHCUZOp8r7BTHRioJGO3Qt+Hm2G3i5acO OBnLqfLiJk63pF5vX3Qt/4rtQka89SBjUI9M17PHEfGHJ/8i3eGH9TzcD7muQe/d AjXVMYGC4I8XC6wBP9y7kHTh3S4VDy95APWinacfomBq7kJe3rB3OBuTKfAT6chx QhrVT/pIQMrmJdKNRlAgPmT3kWO6HUeeShYiTdjMZgJHiwIUw1JaMJgxTkLLBwZD Lr8BDifYI95D6DMrdsYH3uzu+TgRyo/WQ37jHiZ6l7TNnCM4JeRtVcjhnEXepGbo cezY69ZYxquO5br9vZc6bXwu+qc+ecjH5FRyuxbq2lgWUVKcHVzggOV2g1veLzLU qxdpp6c2HBGj9roPQSWy/o7fNOGKcaQ1baTcIHUpo3cctQL1zbZUC1g8ibP3Zkl2 W0kkFe6l1svgMp+v9vgeoDh2w8XEJbLRu5wnLWMqSidF92vbqwWvZZrgFb5PSfPd qvXEnzO97S6oQzC0WwkZj0TfBV3Yq80IJNWVzbx2XqW6fbC7q/rndAjRwp8kCNbB mhwI+u7rl1GIZbrwjlV9owKorSGmg3kOLKB1kTLmRm36IEBGe9J/p0zlSXpU1ZzH P2A/ =NkUw -----END PGP SIGNATURE----- --=-=-=--