Help me to hide grub menu again

GRUB menu appeared after I installed Win 11 my other drive. Now I formatted that drive since i don’t need Windows anymore but GRUB stayed even when Fedora 11 is my only system.

/etc/default/grub looks like this:

Things i tried:
sudo grub2-editenv - set menu_auto_hide=1
sudo grub2-mkconfig -o /etc/grub2-efi.cfg

and

sudo grub2-editenv - set menu_auto_hide=2

Both with no luck. I still see GRUB menu on boot :frowning:

GRUB_TIMEOUT=5 means grub will linger for five seconds.

So:

GRUB_TIMEOUT=0

And then:

sudo grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg

Also may be you want to try to create blank (new) grubenv then add again menu_auto_hide=1.

sudo grub2-editenv - create
sudo grub2-editenv - set menu_auto_hide=1

# Check it with:
sudo cat /boot/grub2/grubenv

# May be you also need to recreate `grub.cfg`

I tested:

sudo grub2-editenv - create
sudo grub2-editenv - set menu_auto_hide=1

But GRUB menu still appear on boot. I even double checked my /boot/efi/EFI/ partition and there were no traces of Microsoft. GRUB menu does not show any other OS installed, just this Fedora install and 3 older kernels.

Have you set grub timeout to 0 and update with mkconfig.

Yes. I addet:
GRUB_TIMEOUT=0

And run:

sudo grub2-mkconfig -o /etc/grub2-efi.cfg
93ee0db2bc7d063849f9e57c0d0cab2cf6863823.png

GRUB appears as before.

I don’t understand how this has to be so hard. If have only Fedora installed there is no point to see GRUB menu on every boot :frowning:

Edit: i think I accidentally solved my problem. I had to do like @bluishhumility suggested but I needed to type: sudo grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg to get it work

Thank you all for your time and kindness for helping me! :heart:

1 Like

Hi, btw the default location for grub.cfg should be in /boot/grub2/grub.cfg either for UEFI and non-UEFI. The /boot/efi/EFI/fedora/grub.cfg should not contain complete/real grub.cfg, but only a pointer to other location which /boot/grub2/grub.cfg. Bellow are default contain of /boot/efi/EFI/fedora/grub.cfg

search --no-floppy --fs-uuid --set=dev <replace-with-UUID-of-/boot-partition>
set prefix=($dev)/grub2
export $prefix
configfile $prefix/grub.cfg

It also explain why your grubenv doesn’t work since the file located in /boot/grub2/ and not in /boot/efi/EFI/fedora/.

You could continue to use /boot/efi/EFI/fedora/grub.cfg as grub2-mkconfig output destination. But if you want to reset it as default Fedora 35, you could use this Fedora wiki on part Instructions for UEFI-based systems.

1 Like

Thanks for explaining I have no I idea how my config was so messed up. I did the reset you mentioned and now my system boots up straitght to Fedora even without: GRUB_TIMEOUT=0 line.

[quote=“oprizal, post:8, topic:77797”]
You could continue to use /boot/efi/EFI/fedora/grub.cfg as grub2-mkconfig output destination. [/quote]

I would not even offer that option since every later kernel update would update the grub.cfg at /boot/grub2/grub.cfg as well as the grub.env located there. However, booting would never see the updates unless the file /boot/efi/EFI/fedora/grub.cfg were restored to the default content.

Restoring the default content is as easy as deleting the file then running sudo dnf reinstall grub2-efi since that will, by design, include the proper UUID for booting in the new /boot/efi/EFI/fedora/grub.cfg file it will create.

Users of fedora 34 & 35 (and future versions) should be encouraged to use the correct path, which is also linked as /etc/grub2.cfg and /etc/grub2-efi.cfg.

1 Like

:thinking: actually, most likely no. Upgrading kernel only create new file inside /boot/loader/entries/ and grub.cfg will load file inside thus folder then showing it on boot loader list.