Grub changes question

So, someone help me help my stupid self please.
I reinstalled Debian testing, when I did that I no longer have a dual boot system.
Before I reinstalled I had Debian and Windows in the grub boot menu, now I don’t.
I read this:> News. Debian

grub2 (2.06-1) unstable; urgency=medium

  • Boot menu entries for other operating systems are no longer generated by
    default. To re-enable this, set GRUB_DISABLE_OS_PROBER=false in
    /etc/default/grub.
    Which that line isn’t in that file or /etc/default/grub.d
    Okay, well that sucks I thought and ran
fdisk -l
Disk /dev/sda: 931.51 GiB, 1000204886016 bytes, 1953525168 sectors
Disk model: WDC WD10EZEX-00W
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: F00D5518-A994-4BE0-8D97-252F01C1D14F

Device         Start        End    Sectors   Size Type
/dev/sda1       2048    1050623    1048576   512M EFI System
/dev/sda2    1050624  196362239  195311616  93.1G Linux filesystem
/dev/sda3  196362240  208080895   11718656   5.6G Linux swap
/dev/sda4  208080896  219799551   11718656   5.6G Linux filesystem
/dev/sda5  219799552  610424831  390625280 186.3G Linux filesystem
/dev/sda6  610424832 1953523711 1343098880 640.4G Linux filesystem


Disk /dev/sdb: 232.89 GiB, 250059350016 bytes, 488397168 sectors
Disk model: WDC WD2500AAJS-0
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: 402470A2-FDBD-4188-8285-2DFCDA630B56

Device         Start       End   Sectors   Size Type
/dev/sdb1       2048    206847    204800   100M EFI System
/dev/sdb2     206848    239615     32768    16M Microsoft reserved
/dev/sdb3     239616 487350924 487111309 232.3G Microsoft basic data
/dev/sdb4  487352320 488394751   1042432   509M Windows recovery environment

Then I ran:

sudo os-prober
/dev/sdb1@/efi/Microsoft/Boot/bootmgfw.efi:Windows Boot Manager:Windows:efi

and added the line to my /etc/default/grub and now it looks like:

If you change this file, run ‘update-grub’ afterwards to update

/boot/grub/grub.cfg.

For full documentation of the options in this file, see:

info -f grub -n ‘Simple configuration’

GRUB_DISABLE_OS_PROBER=false
GRUB_DEFAULT=0
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR=lsb_release -i -s 2> /dev/null || echo Debian
GRUB_CMDLINE_LINUX_DEFAULT=“quiet”
GRUB_CMDLINE_LINUX=“”

Uncomment to enable BadRAM filtering, modify to suit your needs

This works with Linux (no patch required) and with any kernel that obtains

the memory map information from GRUB (GNU Mach, kernel of FreeBSD …)

#GRUB_BADRAM=“0x01234567,0xfefefefe,0x89abcdef,0xefefefef”

Uncomment to disable graphical terminal (grub-pc only)

#GRUB_TERMINAL=console

The resolution used on graphical terminal

note that you can use only modes which your graphic card supports via VBE

you can see them in real GRUB with the command `vbeinfo’

#GRUB_GFXMODE=640x480

Uncomment if you don’t want GRUB to pass “root=UUID=xxx” parameter to Linux

#GRUB_DISABLE_LINUX_UUID=true

Uncomment to disable generation of recovery mode menu entries

#GRUB_DISABLE_RECOVERY=“true”

Uncomment to get a beep at grub start

#GRUB_INIT_TUNE=“480 440 1”
and when I run sudo update-grub
I get this: [QUOTE]Generating grub configuration file …
Found background image: /usr/share/images/desktop-base/desktop-grub.png
Found linux image: /boot/vmlinuz-5.18.0-4-amd64
Found initrd image: /boot/initrd.img-5.18.0-4-amd64
Found linux image: /boot/vmlinuz-5.17.0-1-amd64
Found initrd image: /boot/initrd.img-5.17.0-1-amd64
Adding boot menu entry for UEFI Firmware Se I get the grub menu to show Windows in Grub like it used to?

You are seeking help to run Windows? :smiling_imp: jk

Hm did you run update-grub after reinstall of deb testing?

Chroot into Debian and run:

update-grub

…see: Grub2/Installing - Community Help Wiki

Debian wiki: GrubEFIReinstall - Debian Wiki

I still have a habit of finding fixes to issues for any distro via Arch Linux wiki. If not the direct or complete answer, most times reading will lead me down to finding solution. Give a try:
https://wiki.archlinux.org/title/GRUB#Detecting_other_operating_systems

Well, yeah even the ugly girl needs sex once in a while too :blush:
So here’s what I wound up doing:

  1. create an empty file /etc/default/grub.d/ 40_custom ((It’s a Debian thing,there’s also just grub in the default folder)
  2. add these lines to it: `GRUB_DISABLE_OS_PROBER=false

menuentry ‘Windows Boot Manager’ --class windows --class os {
insmod part_gpt
insmod fat
set root=‘hd1,gpt1’
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd1,gpt1 --hint-efi=hd1,gpt1 3A4C-64E5
else
search --no-floppy --fs-uuid --set=root 3A4C-64E5
fi
chainloader /EFI/Microsoft/Boot/bootmgfw.efi
}

`
3. run update-grub as sudo
4. reboot to see if Windows was an option.
5. Boot into windows
And that’s the weird-ish part,everything I could find told me to mount Windows, run os-prober then grub-update. One told me to edit grub.conf with GRUB_DISABLE_OS_PROBER=false (which didn’t work either).
It may have to do with this change:

News.Debian grub2 (2.06-1) unstable; urgency=medium

  • Boot menu entries for other operating systems are no longer generated by
    default. To re-enable this, set GRUB_DISABLE_OS_PROBER=false in
    /etc/default/grub.
    But I swore I marked the thing to use other OS’s (I could be wrong, I am getting old). But anyway I got it fixed and now if I have to (hopefully never) I can boot into Windows again.
1 Like

Have me laughing out loud during work hours. :smile:

1 Like