Grub entry help! Grub doesn't add Nobara entry to the menu

Hey everyone! Yesterday, I tried setting up an install of Nobara linux on a different drive than my Endeavor install. More specifically a partition of a windows drive which I had separated for ubuntu a long time ago. For some reason, although Nobara was installed correctly, Grub does not add a menu entry at the start, which makes the system unbootable as the efi partition is also being used by windows, which makes the drive boot to it on default instead of Nobara when trying to boot from bios.

os-prober does detect Nobara and Windows separately, but only the Windows boot manager option is added to the menu. Nobara is completely missing from any grub.cfg files.
Here’s the output of sudo grub-mkconfig -o /boot/grub/grub.cfg

Generating grub configuration file ...
Found theme: /usr/share/grub/themes/catppuccin-mocha-grub-theme/theme.txt
Found linux image: /boot/vmlinuz-linux
Found initrd image: /boot/amd-ucode.img /boot/initramfs-linux.img
Found fallback initrd image(s) in /boot:  amd-ucode.img initramfs-linux-fallback.img
Found linux image: /boot/vmlinuz-linux65-tkg-pds-llvm
Found initrd image: /boot/amd-ucode.img /boot/initramfs-linux65-tkg-pds-llvm.img
Found fallback initrd image(s) in /boot:  amd-ucode.img initramfs-linux65-tkg-pds-llvm-fallback.img
Warning: os-prober will be executed to detect other bootable partitions.
Its output will be used to detect bootable binaries on them and create new boot entries.
Found Windows Boot Manager on /dev/sda1@/efi/Microsoft/Boot/bootmgfw.efi
Found Nobara Linux 40 (GNOME Edition) on /dev/sda6
Adding boot menu entry for UEFI Firmware Settings ...
done

It also might be good to mention that Nobara uses the same EFI partition as Windows, but separates the boot partition from the root partition. The boot partition is /dev/sda5 and it is ext4, while the root partition is /dev/sda6 and is btrfs.

Hey @Cheesy,
You need
/etc/grub.d/40_custom

#!/bin/sh
exec tail -n +3 $0
# This file provides an easy way to add custom menu entries.  Simply type the
# menu entries you want to add after this comment.  Be careful not to change
# the 'exec tail' line above.
menuentry "Nobara" {
    insmod part_gpt
    insmod btrfs
    insmod ext2
    rmmod tpm

    search --set=root --fs-uuid 1FA5-65C5
    chainloader /EFI/fedora/grubx64.efi
}

replace 1FA5-65C5 with the UUID of your partition where /boot/efi/EFI/fedora can be found
blkid /dev/sdxy

sudo update-grub2
or
grub-mkconfig -o /boot/grub/grub.cfg

Edit: Until ‘Intel Platform Trust Technology’ was not disabled in BIOS there were TPM related
warnings during grub boot. Now it works ‘normally’.
Based on this

1 Like