help-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GRUB search doesn't set btrfs subvolume


From: Lyubomir Parvanov
Subject: Re: GRUB search doesn't set btrfs subvolume
Date: Sun, 12 Mar 2023 12:00:05 +0200

I actually just fixed the path by myself in the /boot/efi config file, no
need to reinstall and possibly get into missing modules and etc. It works
now.
Thank you very much for your time in helping me too!

On Sun, 12 Mar 2023 at 11:15, Lyubomir Parvanov <liubomirwm@gmail.com>
wrote:

> On Sun, 12 Mar 2023 at 08:21, Andrei Borzenkov <arvidjaar@gmail.com>
> wrote:
>
>> On 11.03.2023 22:46, Lyubomir Parvanov wrote:
>> >>
>> >> And what is this search command?
>> >>
>> > https://www.gnu.org/software/grub/manual/grub/html_node/search.html
>> >
>>
>> I know what grub search command is. You said "call to the search command
>> in order to set the prefix environment variable. But as far as I
>> understand it doesn't take into account the btrfs subvolumes" and I
>> asked you to show this search command invocation.
>>
> There's the menuentry named "Ubuntu" (the one that is booted) with the
> following call on line 181 of the grub.cfg file that i attached:
> search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2
> --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2
>  5f772e81-6e8f-4194-b9b7-5de280170447
>
> I just got up this morning and had an eureka moment now:
> 1. I remembered that more than a week ago i actually moved grub from the
> root btrfs volume to a subvolume.
> 2. I wondered if it's not searching for something built into its executable
> 3. i found out the initial grub config at /boot/efi/EFI/ubuntu/grub.cfg
> with the following content:
> search.fs_uuid 5f772e81-6e8f-4194-b9b7-5de280170447 root hd0,gpt2
> set prefix=($root)'/grub'
> configfile $prefix/grub.cfg
>
> So i think i understand what's happening here. GRUB can't find it's main
> config because the bootstrap config in the boot/efi tells it/still thinks
> it's located on the root btrfs instead of on a subvolume.
> I just didn't think of this back at the moment cause after all it stays
> the same /boot/efi path. But i totally didn't realize that this is itself
> relative to the root/prefix.
> I think i gotta reinstall grub and see if that'll fix things.
>


reply via email to

[Prev in Thread] Current Thread [Next in Thread]