View previous topic :: View next topic |
Author |
Message |
g0rg0n Tux's lil' helper
Joined: 18 Feb 2006 Posts: 83
|
Posted: Sun Feb 19, 2023 9:16 am Post subject: sys-boot/os-prober-1.81-r1 no longer detects Windows |
|
|
After upgrading to sys-boot/os-prober-1.81-r1, os-prober is no longer able to locate Windows bootmgfw.efi.
Code: |
theoffice /boot/efi # cd EFI
theoffice /boot/efi/EFI # ls -alF
total 6
drwxr-xr-x 6 root root 1024 Jan 9 20:42 ./
drwxr-xr-x 4 root root 1024 Jan 1 1970 ../
drwxr-xr-x 2 root root 1024 Oct 15 03:29 Boot/
drwxr-xr-x 4 root root 1024 Jan 9 20:42 dell/
drwxr-xr-x 2 root root 1024 Oct 19 12:54 gentoo/
drwxr-xr-x 4 root root 1024 Oct 15 03:24 Microsoft/
theoffice /boot/efi/EFI # cd Microsoft/
theoffice /boot/efi/EFI/Microsoft # ls
Boot Recovery
theoffice /boot/efi/EFI/Microsoft # cd Boot/
theoffice /boot/efi/EFI/Microsoft/Boot # ls -alF
total 5813
drwxr-xr-x 40 root root 5120 Oct 15 03:24 ./
drwxr-xr-x 4 root root 1024 Oct 15 03:24 ../
-rwxr-xr-x 1 root root 32768 Feb 19 14:52 BCD*
-rwxr-xr-x 1 root root 32768 Oct 15 03:24 BCD.LOG*
-rwxr-xr-x 1 root root 0 Oct 15 03:29 BCD.LOG1*
-rwxr-xr-x 1 root root 0 Oct 15 03:29 BCD.LOG2*
drwxr-xr-x 2 root root 1024 Oct 15 03:29 bg-BG/
-rwxr-xr-x 1 root root 1587552 Jan 11 18:26 bootmgfw.efi*
theoffice ~ # grub-mkconfig -o /boot/grub/grub.cfg
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-6.1.12-gentoo-dist
Found initrd image: /boot/initramfs-6.1.12-gentoo-dist.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.
Adding boot menu entry for UEFI Firmware Settings ...
done
theoffice ~ # cat /boot/grub/grub.cfg
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#
### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
load_env
fi
if [ "${next_entry}" ] ; then
set default="${next_entry}"
set next_entry=
save_env next_entry
set boot_once=true
else
set default="0"
fi
if [ x"${feature_menuentry_id}" = xy ]; then
menuentry_id_option="--id"
else
menuentry_id_option=""
fi
export menuentry_id_option
if [ "${prev_saved_entry}" ]; then
set saved_entry="${prev_saved_entry}"
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi
function savedefault {
if [ -z "${boot_once}" ]; then
saved_entry="${chosen}"
save_env saved_entry
fi
}
function load_video {
if [ x$feature_all_video_module = xy ]; then
insmod all_video
else
insmod efi_gop
insmod efi_uga
insmod ieee1275_fb
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
fi
}
if [ x$feature_default_font_path = xy ] ; then
font=unicode
else
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root afa3a06f-dc39-4d41-88da-5a38a814efc0
font="/usr/share/grub/unicode.pf2"
fi
if loadfont $font ; then
set gfxmode=auto
load_video
insmod gfxterm
set locale_dir=$prefix/locale
set lang=en_US
insmod gettext
fi
terminal_output gfxterm
if [ x$feature_timeout_style = xy ] ; then
set timeout_style=menu
set timeout=5
# Fallback normal timeout code in case the timeout_style feature is
# unavailable.
else
set timeout=5
fi
### END /etc/grub.d/00_header ###
### BEGIN /etc/grub.d/10_linux ###
menuentry 'Gentoo GNU/Linux' --class gentoo --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-afa3a06f-dc39-4d41-88da-5a38a814efc0' {
load_video
if [ "x$grub_platform" = xefi ]; then
set gfxpayload=keep
fi
insmod gzio
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root db5a42e9-18c5-4487-9bed-598b1abcb8d7
echo 'Loading Linux 6.1.12-gentoo-dist ...'
linux /vmlinuz-6.1.12-gentoo-dist root=UUID=afa3a06f-dc39-4d41-88da-5a38a814efc0 ro quiet
echo 'Loading initial ramdisk ...'
initrd /initramfs-6.1.12-gentoo-dist.img
}
submenu 'Advanced options for Gentoo GNU/Linux' $menuentry_id_option 'gnulinux-advanced-afa3a06f-dc39-4d41-88da-5a38a814efc0' {
menuentry 'Gentoo GNU/Linux, with Linux 6.1.12-gentoo-dist' --class gentoo --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-6.1.12-gentoo-dist-advanced-afa3a06f-dc39-4d41-88da-5a38a814efc0' {
load_video
if [ "x$grub_platform" = xefi ]; then
set gfxpayload=keep
fi
insmod gzio
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root db5a42e9-18c5-4487-9bed-598b1abcb8d7
echo 'Loading Linux 6.1.12-gentoo-dist ...'
linux /vmlinuz-6.1.12-gentoo-dist root=UUID=afa3a06f-dc39-4d41-88da-5a38a814efc0 ro quiet
echo 'Loading initial ramdisk ...'
initrd /initramfs-6.1.12-gentoo-dist.img
}
menuentry 'Gentoo GNU/Linux, with Linux 6.1.12-gentoo-dist (recovery mode)' --class gentoo --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-6.1.12-gentoo-dist-recovery-afa3a06f-dc39-4d41-88da-5a38a814efc0' {
load_video
if [ "x$grub_platform" = xefi ]; then
set gfxpayload=keep
fi
insmod gzio
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root db5a42e9-18c5-4487-9bed-598b1abcb8d7
echo 'Loading Linux 6.1.12-gentoo-dist ...'
linux /vmlinuz-6.1.12-gentoo-dist root=UUID=afa3a06f-dc39-4d41-88da-5a38a814efc0 ro single
echo 'Loading initial ramdisk ...'
initrd /initramfs-6.1.12-gentoo-dist.img
}
}
### END /etc/grub.d/10_linux ###
### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###
### BEGIN /etc/grub.d/30_os-prober ###
### END /etc/grub.d/30_os-prober ###
### BEGIN /etc/grub.d/30_uefi-firmware ###
menuentry 'UEFI Firmware Settings' $menuentry_id_option 'uefi-firmware' {
fwsetup
}
### END /etc/grub.d/30_uefi-firmware ###
### BEGIN /etc/grub.d/40_custom ###
# 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.
### END /etc/grub.d/40_custom ###
### BEGIN /etc/grub.d/41_custom ###
if [ -f ${config_directory}/custom.cfg ]; then
source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f $prefix/custom.cfg ]; then
source $prefix/custom.cfg
fi
### END /etc/grub.d/41_custom ###
theoffice ~ # fdisk -l
Disk /dev/nvme0n1: 476.94 GiB, 512110190592 bytes, 1000215216 sectors
Disk model: Micron 2300 NVMe 512GB
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: BEC4DB49-E435-2146-AB61-B1BF26A9D7EB
Device Start End Sectors Size Type
/dev/nvme0n1p1 2048 206847 204800 100M EFI System
/dev/nvme0n1p2 206848 239615 32768 16M Microsoft reserved
/dev/nvme0n1p3 239616 533851662 533612047 254.4G Microsoft basic data
/dev/nvme0n1p4 533852160 536870911 3018752 1.4G Windows recovery environment
/dev/nvme0n1p5 536870912 537919487 1048576 512M Linux filesystem
/dev/nvme0n1p6 537919488 546308095 8388608 4G Linux swap
/dev/nvme0n1p7 546308096 1000215182 453907087 216.4G Linux filesystem
Disk /dev/zram2: 14 GiB, 15032385536 bytes, 3670016 sectors
Units: sectors of 1 * 4096 = 4096 bytes
Sector size (logical/physical): 4096 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
theoffice ~ #
|
os-prober-1.81 is able to find bootmgfw.efi correctly:
Code: | theoffice /tmp # !502
grub-mkconfig -o /boot/grub/grub.cfg
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-6.1.12-gentoo-dist
Found initrd image: /boot/initramfs-6.1.12-gentoo-dist.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/nvme0n1p1@/EFI/Microsoft/Boot/bootmgfw.efi
Adding boot menu entry for UEFI Firmware Settings ...
done |
Has anyone encountered this issue as well? _________________ nicewarm.coffee |
|
Back to top |
|
|
sabayonino Veteran
Joined: 03 Jan 2012 Posts: 1016
|
|
Back to top |
|
|
sMueggli Guru
Joined: 03 Sep 2022 Posts: 374
|
Posted: Sun Feb 19, 2023 10:49 am Post subject: |
|
|
It looks like a bug. |
|
Back to top |
|
|
haf1zoglu n00b
Joined: 28 Nov 2022 Posts: 12
|
Posted: Sun Feb 19, 2023 12:53 pm Post subject: |
|
|
-->Update Grub configuration: Run sudo grub-mkconfig -o /boot/grub/grub.cfg
-->Check the OS-prober configuration: Ensure GRUB_DISABLE_OS_PROBER=false in /etc/default/grub
-->Check UEFI boot entries: Verify the Windows Boot Manager entry is present using efibootmgr
-->Reinstall os-prober: Run sudo emerge --unmerge sys-boot/os-prober then sudo emerge sys-boot/os-prober |
|
Back to top |
|
|
g0rg0n Tux's lil' helper
Joined: 18 Feb 2006 Posts: 83
|
Posted: Sun Feb 19, 2023 11:30 pm Post subject: |
|
|
Code: | GRUB_DISABLE_OS_PROBER="false"
|
This is already set, otherwise os-prober-1.81 wouldn't work as well _________________ nicewarm.coffee |
|
Back to top |
|
|
g0rg0n Tux's lil' helper
Joined: 18 Feb 2006 Posts: 83
|
Posted: Sat Feb 25, 2023 2:43 am Post subject: |
|
|
For anyone wondering:
bug fix for 830655 seems to be the trigger.
Changing following line 333 in /usr/share/os-prober/common.sh fixes the issue:
Code: | - while read -r x x dev x mount x x fs x; do
+ while read -r x x dev x mount x x x fs x; do |
_________________ nicewarm.coffee
Last edited by g0rg0n on Sat Feb 25, 2023 3:01 am; edited 1 time in total |
|
Back to top |
|
|
grknight Retired Dev
Joined: 20 Feb 2015 Posts: 1681
|
Posted: Sat Feb 25, 2023 2:57 am Post subject: |
|
|
g0rg0n wrote: | For anyone wondering:
bug fix for 830655 seems to be the trigger.
Changing following line 333 in /usr/share/os-prober/common.sh fixes the issue:
Code: | - while read -r x x dev x mount x x fs x; do
+ while read -r x x dev x mount x x x fs x; do |
|
If this is true, then it comes from a patch in the gentoo repo at sys-boot/os-prober/files/os-prober-1.81-boot-detected-twice.patch |
|
Back to top |
|
|
|