PJ-Singh-001 / Cubic

The Official Web Site for Cubic (Custom Ubuntu ISO Creator) (https://github.com/PJ-Singh-001/Cubic)
822 stars 47 forks source link

Grub doesn't load configuration automatically, causing OS to not boot after installing #254

Open EnterTheVoid-x86 opened 1 year ago

EnterTheVoid-x86 commented 1 year ago

Describe the question

After installation, I can't boot my OS without typing configfile /efi/esteros/grub.cfg first

What you have tried

Replace GRUB_DISTRIBUTOR with . /etc/os-release ; echo $NAME

Expected behavior

The OS loads automatically

OS Information (please complete the following information):

Cubic Information (please complete the following information):

Screenshots

image

natanjunges commented 11 months ago

I had the same issue. It happens because grub-install will install GRUB in EFI/<ID>/, where ID is the ID field from /etc/os-release. As Ubuntu uses a Secure Boot signed GRUB image, it will always look for grub.cfg in EFI/ubuntu/, regardless of what is in /etc/os-release. It can't be changed because doing so would invalidate the signature. The workaround I used was to force Ubuntu to not use the signed GRUB image, which means Secure Boot doesn't work and has to be disabled. If you want to keep using Secure Boot, you will have to change the path where grub-install installs GRUB back to EFI/ubuntu/.

lisymail commented 3 months ago

I had the same issue. It happens because grub-install will install GRUB in EFI/<ID>/, where ID is the ID field from /etc/os-release. As Ubuntu uses a Secure Boot signed GRUB image, it will always look for grub.cfg in EFI/ubuntu/, regardless of what is in /etc/os-release. It can't be changed because doing so would invalidate the signature. The workaround I used was to force Ubuntu to not use the signed GRUB image, which means Secure Boot doesn't work and has to be disabled. If you want to keep using Secure Boot, you will have to change the path where grub-install installs GRUB back to EFI/ubuntu/.

@natanjunges how resolve it? I customized the iso and after changing the ID in os-release, the same problem as above was reported when starting through uefi.

lisymail commented 3 months ago

@PJ-Singh-001