Subject: Re: bug#40999: GRUB prevents booting a degraded RAID1 array atop LUKS

From: Giovanni Biscuolo <[email-masked]>
Date: Wed, 11 Aug 2021 16:45:03 +0200

Hello Maxim,

Maxim Cournoyer <[email-masked]> writes:

[...]

>> On a system where:
>>
>> 1) Each disks comprising the array is fully LUKS encrypted
>> 2) Each mapped disk is made part of a Btrfs RAID1 array
>>
>> When attempting to boot the system after pulling out (in BIOS or using
>> the cable) the drive to simulate a complete disk failure, GRUB hangs,
>> prompting for the LUKS password of the disappeared drive and
>> (unsurprisingly) failing to open it.

[...]

> 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

> should be smart enough to realize that oh, that's Btrfs RAID1, it
> ought to work in degraded mode, so let's keep going.

I (still) don't have a Guix System to test your setup and (try to) patch
thing up, so we need more info to debug the situation.

Can you please provide the output of the "ls" command and the "set"
command from the grub rescue shell?

Also, please what is your /proc/cmdline (when Linux correcly boots)?

Best regards, Gio

-- 
Giovanni Biscuolo

Xelera IT Infrastructures