Windows entry missing from grub menu after kernel update with MSM

windows
msm

#1

When I reboot my system after a kernel update through Manjaro Settings Manager, the grub boot menu does not display the “Windows” option on my dual-boot systems.

I need to manually execute sudo grub-mkconfig -o /boot/grub/grub.cfg to make it reappear.

This has been going on for some time. I am on Manjaro KDE and Cinnamon on different systems and all exhibit the same behavior.


MSM not detecting windows upon kernel installation
Old Threads/"Necro-Bumping" shall be encouraged unless thread is closed
#2

Do you have os-prober installed?


#3

No I don’t.


#4

os-prober is needed for the update to find your windows installation


#5

OK, I will install it. Just curious: why isn’t the system complaining that this dependency is missing then?


#6

It is an optional dependency - not everyone dualboots with windows


#7

I see. Good to know. Thanks.


#8

A post was split to a new topic: MSM not detecting windows upon kernel installation


#9

I have os-prober installed, and I have the same problem. Running grub-mkconfig manually does find the Windows installation. When I update the kernel using Manjaro Settings Manager and reboot after successfull update, the entry for the Windows partition is missing. It is as if Manjaro Settings Manager does not use os-prober.


#10

The problem is still present for me too. Installing os-prober has not changed anything.

It is a small thing but a real pain in the b*** as I almost always forget to run grub-mkconfig manually after a kernel update.


#11

I got the same problem after the last upgrade. os-prober installed, I did run sudo grub-mkconfig the problem still remains.


#12

have you tried running os-proper op-prober on the cli?

what is the output?


#13

I think you mean os-prober:

/dev/sda1:Windows 10:Windows:chain

#14

[mladen@mladen-pc ~]$ sudo os-prober
[sudo] password for mladen:
/dev/sdb1:Windows 10:Windows:chains:

sudo grub-mkconfig
didn’t solve the issue.

I see in the output

### BEGIN /etc/grub.d/30_os-prober ###
Found Windows 10 on /dev/sdb1
menuentry 'Windows 10 (on /dev/sdb1)' --class windows --class os $menuentry_id_option 'osprober-chain-283891173890E4DA' {
	insmod part_msdos
	insmod ntfs
	set root='hd1,msdos1'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint-bios=hd1,msdos1 --hint-efi=hd1,msdos1 --hint-baremetal=ahci1,msdos1  283891173890E4DA
	else
	  search --no-floppy --fs-uuid --set=root 283891173890E4DA
	fi
	parttool ${root} hidden-
	drivemap -s (hd0) ${root}
	chainloader +1
}
### END /etc/grub.d/30_os-prober ###

#15

I did. :slight_smile:

if you don’t point it to the cfg file it won’t work

sudo grub-mkconfig -o /boot/grub/grub.cfg

I hope you do know that?


#16

Yes, That is what I wrote in the OP. My point is that running sudo grub-mkconfig -o /boot/grub/grub.cfg always works. But it is when I do the kernel update through Manjaro Settings Manager that the grub boot menu does not display the “Windows” option on my dual-boot systems.


#17

The - I hope you know thing - was not for you it was for @adamovic
Have you tried to a cli install on a kernel(a kernel you do not have installed)

sudo pacman -Syu linux414

If that works correct and you get windows in your grub then it must be due the way MSM and/or MHWD handles the process of regenerating grub.cfg.

To eliminate MHWD as the cause you could try installing the mhwd-tui package which is a helper package for mhwd.

sudo pacman -Syu mhwd-tui
mhwd-tui

Use the interface to install a new kernel and check if your grub.cfg is generated correct.


#18

Installation of kernel with pacman

sudo pacman -Syu linux415

[skipping to relevant section]

(3/4) Updating Grub-Bootmenu
Generating grub configuration file ...
Found background: /usr/share/grub/background.png
Found Intel Microcode image
Found linux image: /boot/vmlinuz-4.15-x86_64
Found initrd image: /boot/initramfs-4.15-x86_64.img
Found initrd fallback image: /boot/initramfs-4.15-x86_64-fallback.img
Found linux image: /boot/vmlinuz-4.14-x86_64
Found initrd image: /boot/initramfs-4.14-x86_64.img
Found initrd fallback image: /boot/initramfs-4.14-x86_64-fallback.img
Found linux image: /boot/vmlinuz-4.9-x86_64
Found initrd image: /boot/initramfs-4.9-x86_64.img
Found initrd fallback image: /boot/initramfs-4.9-x86_64-fallback.img
Found Windows 10 on /dev/sda1
Found memtest86+ image: /boot/memtest86+/memtest.bin
done
(4/4) Arming ConditionNeedsUpdate...

After reboot the Windows 10 option is present.

Removal through Manjaro Settings Manager

Linux415

Starting
checking dependencies...
Packages (1) linux415-4.15.r171130.g9e0600f-1
Total Removed Size:  116.86 MiB
:: Do you want to remove these packages? [Y/n]
:: Processing package changes...
removing linux415...
:: Running post-transaction hooks...
(1/2) Updating Grub-Bootmenu
Generating grub configuration file ...
Found background: /usr/share/grub/background.png
Found Intel Microcode image
Found linux image: /boot/vmlinuz-4.14-x86_64
Found initrd image: /boot/initramfs-4.14-x86_64.img
Found initrd fallback image: /boot/initramfs-4.14-x86_64-fallback.img
Found linux image: /boot/vmlinuz-4.9-x86_64
Found initrd image: /boot/initramfs-4.9-x86_64.img
Found initrd fallback image: /boot/initramfs-4.9-x86_64-fallback.img
Found memtest86+ image: /boot/memtest86+/memtest.bin
done
(2/2) Arming ConditionNeedsUpdate...


Done ...

After reboot the Windows 10 option is NOT present. Indeed, line Found Windows 10 on /dev/sda1 is missing from the Updating Grub-Bootmenu section of the log.

Installing mhwd-tui does not change anything. Installation and removal of the kernel using Manjaro Settings Manager does not detect windows 10.


#19

So it would seem your issue is MSM related?

I have a tablet dual-booting with Win10 - I will try the different options - but I think you narrowed it down to a msm issue.

Confirmed. It is a MSM issue.

Using

sudo mhwd-kernel -i linux414

is duly taking my Windows boot into the grub.cfg.

however removing kernel 4.13 using MSM does not.

linux413

Starting
checking dependencies...
Packages (1) linux413-4.13.16-2
Total Removed Size:  98.41 MiB
:: Do you want to remove these packages? [Y/n]
:: Processing package changes...
removing linux413...
:: Running post-transaction hooks...
(1/2) Updating Grub-Bootmenu
Generating grub configuration file ...
Found background: /usr/share/grub/background.png
Found Intel Microcode image
Found linux image: /boot/vmlinuz-4.14-x86_64
Found initrd image: /boot/initramfs-4.14-x86_64.img
Found initrd fallback image: /boot/initramfs-4.14-x86_64-fallback.img
Found linux image: /boot/vmlinuz-4.12-x86_64
Found initrd image: /boot/initramfs-4.12-x86_64.img
Found initrd fallback image: /boot/initramfs-4.12-x86_64-fallback.img
Found linux image: /boot/vmlinuz-4.9-x86_64
Found initrd image: /boot/initramfs-4.9-x86_64.img
Found initrd fallback image: /boot/initramfs-4.9-x86_64-fallback.img
Found memtest86+ image: /boot/memtest86+/memtest.bin
done
(2/2) Arming ConditionNeedsUpdate...

#20

It’s certainly… but why. As msm simply call pacman to install kernel… and you can see that update-grub is called by the hook… but it doesn’t detect windows or call os-prober (should be called by update-grub).

The only difference is with pacman it’s called by sudo… and within msm pacman is called by polkit and dbus… maybe that’s the problem as update-grub call an other executable… and cause problem with polkit?