Grub-update wont co-operate

Hello fellow members. Hope things are well with all.

Previously, when I had MNJ and w10 on two separate SSDs, I was able to choose which OS to boot into from the grub menu entry. Back then I had BIOS (non-uefi) on an older motherboard.
Ever since upgrading my mobo and reinstalling both OS’es [w10 first, then MNJ], this time, I installed w10 on an NVMe and reinstalled MNJ after on the same previously used SSD. Since then, GRUB refuses to detect w10’s entry and I have to set disk priority from uefi as to which OS I need to boot and choose the disk accordingly.

I tried the below guide for creating custom grub_menus, but grub still is adamant.

Can you help me please?
Do let me know if more info is required from my side. Looking forward to your replies.

Thanks!

Hello,

That guide has nothing about Manjaro, and Manjaro grub is a bit different. Also os-prober is disabled by default. Was mentioned in the announcements (that you should read from time to time) way back …

But, if your new Mobo UEFI BIOS is dealing with the boot entries, then add them there, or maybe this will help
https://wiki.manjaro.org/index.php/UEFI_-_Install_Guide#An_alternative:_chainloading_via_GRUB

2 Likes

Screenshot_20210911_154024

Thanks for replying, but as it says over here, os_prober is enabled.
I’m a bit confused!!

Shouldn’t os_prober auto-detect w10 when update-grub is issued?

please post contents of
sudo update-grub

I will show snips of os-prober working for me, but my device may not have same device pathway.

Not OP
sudo update-grub
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 10 on /dev/sdb1

Actually I have changed my method based on the post by @ bogdancovaciu

Disclaimer untested on UEFI/GPT /secure boot motherboard as I still use MBR etc

First I have 2 hard drives (ssd lucky me) one has linux and the other W10. I removed linux and W10 borked because grub was in the MBR of W10 drive. I refuse to use UEFI or GPT etc…anyhow I use W10 to repair mbr, let me know if you have the same issue.

Use root powers to edit /etc/grub.d/40_custom to create a chainloader entry for W10

Use root powers to edit /etc/default/grub so although my entries may differ from mine the intent is to ensure…grub menu is not hidden, grub does not remember last used entry, grub menu is highlighted on your main choice, and personal choice…grub font is huge enough for my eyesight

Then update-grub as below.

Try at own risk but you can always boot a linux usb/cd …change the files and use chroot to update-grub.

Example of a 2 drive system where W10 is on second drive for 40_custom

I am omitting the top of the file and showing the last line and new content with a prefix of / to avoid the hash symbol thinking I wanted large text

The effect of this menu is allow grub to swap to the MBR of the other drive, and as W10 has control of that drive, its bootloader stuff is there and will do its job

/# the ‘exec tail’ line above.

menuentry “W10” {
insmod ntfs
set root=(hd1)
chainloader +1
}

Example of 1 drive system where W10 is on a partition

Untested, is to chainload to a Partition Boot Record (PBR) where W10 is on a partition maybe same drive as your laptop?

Only line below changes from above (for /dev/sda4 as an example for target PBR)

set root=(hd0,4)

Extra Notes

  • grub header loads mbr,gpt, font, graphics, video modules

  • Some people think that as their current grub.cfg shows for /dev/sda1
    set root=‘hd0,msdos1’ that forces them from above example to use

    set root=‘hd0,mddos4’

    but I disagree…keep it simple.

Example of lines to change for /etc/default/grub

GRUB_DEFAULT=0
(there is a hash here)/# GRUB_TIMEOUT_STYLE=hidden
GRUB_SAVEDEFAULT=false
GRUB_GFXMODE=800x600
GRUB_DISABLE_OS_PROBER=true

Notes

  • grub counts from zero menu entries and hard drive
  • grub counts from 1 …partitions (don’t blame me for this )
  • If you rarely go into that other OS you ignore my advice on savedefault
  • The smaller the resolution the easier to read the menu :grin:
  • We need os-prober disabled as we have a better method (IMHO)

Execute

sudo update-grub

to change your grub.cfg

good luck