No Windows Boot option (CSM/Legacy BIOS)

Installed bazzite-nvidia and have lost the boot option for windows. After looking around I've tried the following: 1. ujust regenerate-grub This outputs the following, which is also missing finding the windows boot option
Generating grub configuration file ...
Adding boot menu entry for UEFI Firmware Settings ...
done
Generating grub configuration file ...
Adding boot menu entry for UEFI Firmware Settings ...
done
2. Checking if I've accidentally deleted the windows boot partition. I was trying to be very careful about this, and i can still see all the partitions windows had from before i installed.
sda 8:0 0 931.5G 0 disk
├─sda1 8:1 0 50M 0 part /var/home/<user>/mnt/sda1
├─sda2 8:2 0 805.9G 0 part
├─sda3 8:3 0 100M 0 part /var/home/<user>/mnt/sda3
├─sda4 8:4 0 517M 0 part /var/home/<user>/mnt/sda4
...(bazzite partitions)...
sda 8:0 0 931.5G 0 disk
├─sda1 8:1 0 50M 0 part /var/home/<user>/mnt/sda1
├─sda2 8:2 0 805.9G 0 part
├─sda3 8:3 0 100M 0 part /var/home/<user>/mnt/sda3
├─sda4 8:4 0 517M 0 part /var/home/<user>/mnt/sda4
...(bazzite partitions)...
Also, I've mounted some of the partitions and can see Windows files
<user>@bazzite:~/mnt/sda3/EFI/Microsoft/Boot$ ls *.efi
bootmgfw.efi bootmgr.efi memtest.efi SecureBootRecovery.efi
<user>@bazzite:~/mnt/sda3/EFI/Microsoft/Boot$ ls *.efi
bootmgfw.efi bootmgr.efi memtest.efi SecureBootRecovery.efi
Also some boot looking things in sda1
<user>@bazzite:~/mnt/sda1$ ls
'$RECYCLE.BIN' bootmgr BOOTNXT BOOTSECT.BAK Recovery Recovery.txt 'System Volume Information'
<user>@bazzite:~/mnt/sda1$ ls
'$RECYCLE.BIN' bootmgr BOOTNXT BOOTSECT.BAK Recovery Recovery.txt 'System Volume Information'
I'm not sure what else to check, anyone have any further ideas?
Solution:
So the issue (i believe) was I had left CSM/Legacy BIOS enabled without realising it and bazzite installed non-efi. Because windows was EFI it was not visible in the non-efi grub menu. Updating the BIOS so that i could disable CSM/Legacy BIOS (and Secure Boot which was also not present in my earlier bios version) meant i could reinstall bazzite using grub-efi....
Jump to solution
89 Replies
yogsodoth
yogsodoth3mo ago
Unix & Linux Stack Exchange
Resolving Dual-Boot Issue: Windows Not Showing in GRUB Menu
I recently encountered a dual-boot issue on my Debian 12 system where Windows 10 was not showing up in the GRUB menu after a Debian update. I spent some time troubleshooting the problem and was abl...
adumer
adumerOP3mo ago
I have not, will give that a go I added this to my /etc/grub.d/40_custom, because as far as I could see the boot files were on /dev/sda3. Then ran ujust regenerate-grub
menuentry "Windows 10" {
insmod ntfs
set root=(hd0,3)
chainloader +1
}
menuentry "Windows 10" {
insmod ntfs
set root=(hd0,3)
chainloader +1
}
Can see the new entry, but selecting it does not boot
Linus Xu
Linus Xu3mo ago
I’m pretty sure +1 is not intended for EFI Just checked that my os-prober-generated Windows entry looks like this: menuentry 'Windows Boot Manager (on /dev/nvme0n1p1)' --class windows --class os $menuentry_id_option 'osprober-efi-[redacted]' { insmod part_gpt insmod fat search --no-floppy --fs-uuid --set=root [redacted] chainloader /EFI/Microsoft/Boot/bootmgfw.efi }
adumer
adumerOP3mo ago
That makes more sense, the sda3 partition i have is not ntfs either so don't think i need insmod ntfs Under the [redacted] i'm assuming is a file-system uuid? Do you know how to find that for building this menu entry myself?
Linus Xu
Linus Xu3mo ago
Something like lsblk or blkid The two should be the same and for FAT fses it should be only 8 characters
adumer
adumerOP3mo ago
Found it, thank you
<user>@bazzite:~$ lsblk -o NAME,UUID
NAME UUID
sda
...
├─sda3 XXXX-XXXX
...
<user>@bazzite:~$ lsblk -o NAME,UUID
NAME UUID
sda
...
├─sda3 XXXX-XXXX
...
Ah damn 😦 getting error: ../../grub-core/loader/i386/pc/chainloader.c:213:invalid signature I had to convert from the MBR to UEFI boot mode in windows to get bazzite installed originally, but it looks like sda1 has the old MBR boot stuff. Potentially that's confusing it? This seems like a problem
<user>@bazzite:~$ ls /sys/firmware
acpi dmi memmap
<user>@bazzite:~$ ls /sys/firmware
acpi dmi memmap
Missing efi
TeamLinux01
TeamLinux013mo ago
Does efibootmgr show the Windows boot entry any more?
asen23
asen233mo ago
is csm enabled in bios?
adumer
adumerOP3mo ago
efibootmgr outputs EFI variables are not supported on this system. How can i check this, i looked in my bios recently and it has "Both Legacy and UEFI" option selected currently. I can quickly boot and grab the correct property name
TeamLinux01
TeamLinux013mo ago
Makes me think that CSM was used to install the system, if it is saying EFI variables are not supported.
asen23
asen233mo ago
what is your motherboard?
adumer
adumerOP3mo ago
No description
asen23
asen233mo ago
disable legacy that is csm i believe
adumer
adumerOP3mo ago
asus p8z77-v pro
TeamLinux01
TeamLinux013mo ago
I agree, disable legacy
asen23
asen233mo ago
afaik you should not ever enable csm anymore
adumer
adumerOP3mo ago
Cool, will give a shot
asen23
asen233mo ago
that thing is actually harming performance on modern system
adumer
adumerOP3mo ago
I get a no bootable device dialog now from my bios
TeamLinux01
TeamLinux013mo ago
If the system stops booting bazzite after you disable legacy, the installed OS will have to reinstalled/repaired to boot from EFI.
adumer
adumerOP3mo ago
Ah ok, thankfully still have it on the usb
adumer
adumerOP3mo ago
No description
TeamLinux01
TeamLinux013mo ago
If Windows was installed via EFI and then bazzite was installed via CSM, that can mess things up. I am also wondering why the Windows EFI partition is the third partition on the drive. Usually it as at the beginning of the drive.
adumer
adumerOP3mo ago
I suspect it's because I did a MBR to EFI conversion on it recently Don't know why it would keep around the old bootmgr though?
asen23
asen233mo ago
your system setup are cursed lol, you shouldnt need to do that in modern efi
adumer
adumerOP3mo ago
Yeah i'm slowly realising how much of a snowflake it is
TeamLinux01
TeamLinux013mo ago
Well, if you need to completely start over, I recommend keeping legacy disabled, clear out all partition information on the drive after backing up data and then install Windows first. When Windows asks about the install, choose custom and then click the new button and when it asks for size, change the amount you want for Windows. This will leave the rest of the drive unpartitioned/unformated. Then follow the dual boot guide for partitioning Bazzite.
adumer
adumerOP3mo ago
I couldn't install bazzite at all with it as the old boot, converting let me install bazzite-nvidia-gnome but i had issues with that so reinstalled kde. Then something in that process removed the windows boot option
asen23
asen233mo ago
probably your best bet is to start over 🤷‍♂️
adumer
adumerOP3mo ago
Interestingly enough i can't boot the installation media with Disabled Legacy option, switching back boots I flashed it with ventoy
TeamLinux01
TeamLinux013mo ago
Did you make Ventoy a GPT partition or MBR?
adumer
adumerOP3mo ago
I think i'm going go with this once i get more time to play
asen23
asen233mo ago
also currently it is recommended to use fedora media writer to flash the iso
adumer
adumerOP3mo ago
I remember selecting GPT as it was in the video installation guide. But i'm not 100% sure, and it seems like a likely cause
TeamLinux01
TeamLinux013mo ago
You can see what type of partition table using a partitioning software to view the drive's information.
asen23
asen233mo ago
gpt should be fine
TeamLinux01
TeamLinux013mo ago
I think fdisk -l will list the if it is MBR or GPT. MBT goes with legacy BIOS/CSM and GPT is used with UEFI.
asen23
asen233mo ago
just noticed, you are running intel 2nd/3rd gen cpu wtf
adumer
adumerOP3mo ago
Yeah, old system. I originally tried with gtx670 before hitting into the fact that 470 drivers aren't in Very close to starting over hardware wise too dw
TeamLinux01
TeamLinux013mo ago
A system that old could have buggy UEFI.
asen23
asen233mo ago
i would start updating the bios
TeamLinux01
TeamLinux013mo ago
Is the system on the latest BIOS version?
adumer
adumerOP3mo ago
Would have to check, lost the existing bazzite boot after switching back from "Disabled Legacy", can only see the usb
asen23
asen233mo ago
latest bios is 2013
adumer
adumerOP3mo ago
oh sweet it's back, no idea how it's gpt
Disk /dev/sdc: 14.46 GiB, 15527313408 bytes, 30326784 sectors
...
Disklabel type: gpt
Disk /dev/sdc: 14.46 GiB, 15527313408 bytes, 30326784 sectors
...
Disklabel type: gpt
TeamLinux01
TeamLinux013mo ago
Hmm, then it might be a problem with the system's UEFI implementation. If it isn't on the latest BIOS, updating could fix booting the USB drive.
adumer
adumerOP3mo ago
<user>@bazzite:~$ cat /sys/class/dmi/id/bios_version 0801 Not sure if that's the right command, but doesn't match up to the version code on that latest bios download
TeamLinux01
TeamLinux013mo ago
GitHub
Release Ventoy 1.0.99 release · ventoy/Ventoy
Upadte EFI boot files. Fix the Linpus Lite error on some computer. Fix the issue that VTOY_LINUX_REMOUNT can not take effect in latest openSUSE. (#2551) Fix the issue when installing on /dev/mdX de...
adumer
adumerOP3mo ago
It must be, downloaded a day or two ago Thank you heaps for the help guys
TeamLinux01
TeamLinux013mo ago
Ok. Ventoy stores its EFI boot code in the VTOYEFI partition, so make sure that is there and untouched.
adumer
adumerOP3mo ago
sdc 8:32 1 14.5G 0 disk
├─sdc1 8:33 1 14.4G 0 part
└─sdc2 8:34 1 32M 0 part /run/media/<user>/VTOYEFI
sdc 8:32 1 14.5G 0 disk
├─sdc1 8:33 1 14.4G 0 part
└─sdc2 8:34 1 32M 0 part /run/media/<user>/VTOYEFI
Looks fine, very strange I need to head off soon, but i'll try making sure the BIOS is updated and then switching modes to Disabled Legacy If the USB/Existing Bazzite doesn't boot from then I think i'm resolved to fully refreshing the system
TeamLinux01
TeamLinux013mo ago
Hmm, the USB drive definitely looks correct, so it is probably the motherboard that is acting weird. Also, if the UEFI has a setting to boot an efi file, you might be able to select the grubx64.efi from the ventoy drive. That is a long shot if the mobo supports that, though. I don't suppose that it shows the USB drive in the boot list order with disabled legacy? As in, does it even show up?
adumer
adumerOP3mo ago
Will give it a shot It is showing up now, weird Oh, but not booting. I can choose it as a boot override option, but it goes to a blank screen then back to the BIOS menu Well, my bios version was the stock, after flashing latest I have many more options. Including a CSM menu
Linus Xu
Linus Xu3mo ago
Random idea but could a hybrid MBR be at play here somehow?
adumer
adumerOP3mo ago
Potentially aha? Bit out of my depth
Linus Xu
Linus Xu3mo ago
Try running gdisk on your main drive Available on brew as gptfdisk It’s like fdisk but intended for GPT
adumer
adumerOP3mo ago
So I've disabled CSM which means i can't boot into the current working bazzite but I can now boot back into the bazzite installation media. Afrer booting i thought i screwed up as i only got a blank screen, but switching to hdmi out rather than DVI fixed that New bios also brought secure boot it seems though, as it has a security violation when i try to start. I can switch back CSM to enabled and boot to check
Linus Xu
Linus Xu3mo ago
Do you have any system to boot into in EFI only? I would still advise against reenabling csm
adumer
adumerOP3mo ago
Only the installation media, but need to figure out how to disable secure boot
adumer
adumerOP3mo ago
No description
adumer
adumerOP3mo ago
annoyingly this is all i get, no option to disable
asen23
asen233mo ago
the top option not switchable?
adumer
adumerOP3mo ago
i can't arrow key to it or click on it, so looks not unfortunately
asen23
asen233mo ago
any other menu? possibly something security related
adumer
adumerOP3mo ago
yeah i think i ve found
adumer
adumerOP3mo ago
No description
adumer
adumerOP3mo ago
what an obtuse disable
asen23
asen233mo ago
probably to prevent people accidently deleting their key ig
adumer
adumerOP3mo ago
yeah, the wording is alarming. is this the right option?
Linus Xu
Linus Xu3mo ago
‘will inactive’ Looks like it tho
adumer
adumerOP3mo ago
maybe just in case i'll use that save keys option to the save to the drive that i used for the new bios file Sweet, disabled and can boot fine into ventoy
asen23
asen233mo ago
probably the ventoy secure boot arent compatible with your old bios lol
adumer
adumerOP3mo ago
on me for not updating the bios aha well this is interesting, i retried the install now that i've disabled CSM The installation failed with a message i've seen before... however I can now see a Windows Boot Manager option in my BIOS boot menu
asen23
asen233mo ago
error:1? or different error
adumer
adumerOP3mo ago
Damn, should've taken a picture, it was something along the lines of 'fatal error ... ostree' Will retry and screenshot but can boot properly back into windows, so half success!
asen23
asen233mo ago
if it is error code 1 then you need to clean your efi
asen23
asen233mo ago
Universal Blue
Bazzite Installation Issues & Troubleshooting
ISO Workarounds A generic error may appear during installation. Workaround Video Tutorial: [Getting around the "Code 1" error in Bazzite and other Atomic Desktops when trying to re-install] Alternative Installation Methods Attention: Both workaround methods may have scaling issues with the installer depending on the hardware espec...
adumer
adumerOP3mo ago
Yeah it was exactly that dialog - will follow the video Awesome, After following that it installed successfully, and after reboot i can see both bazzite and windows in the grub menu
Solution
adumer
adumer3mo ago
So the issue (i believe) was I had left CSM/Legacy BIOS enabled without realising it and bazzite installed non-efi. Because windows was EFI it was not visible in the non-efi grub menu. Updating the BIOS so that i could disable CSM/Legacy BIOS (and Secure Boot which was also not present in my earlier bios version) meant i could reinstall bazzite using grub-efi.
adumer
adumerOP3mo ago
I believe the above is all correct, let me know if i got something wrong, else will mark as solution
Linus Xu
Linus Xu3mo ago
Looks like that
asen23
asen233mo ago
Probably nit but its CSM not CMS
adumer
adumerOP3mo ago
Nah good for searching
asen23
asen233mo ago
yeah, btw what did you edit its still CMS, also you could put CSM/Legacy BIOS for keyword
adumer
adumerOP3mo ago
Woops thought i did, have done now
TeamLinux01
TeamLinux013mo ago
You could also install ublue's MOK and enabled SecureBoot, if you wanted. ujust --choose then select the one thay starts with enroll-secure-boot-key or something. Then re-enable SecureBoot in the UEFI settings.
adumer
adumerOP3mo ago
OOC is there any downside to leaving it off? Otherwise i'll enroll the key tonight
asen23
asen233mo ago
afaik it is required if you use windows and you are playing competitive games but in linux the benefit is questionable but there is no harm in turning it on, just some hassle if you need to reenroll key
Want results from more Discord servers?
Add your server