Hi,
I have a dual-boot fedora 39/windows system.
After updating to fedora 39 an incorrect (duplicate) menuentry appeared in the grub boot menu:
$ sudo os-prober --verbose
/dev/nvme0n1p1@/EFI/Microsoft/Boot/bootmgfw.efi:Windows Boot Manager:Windows:efi
/dev/sda1@/EFI/Microsoft/Boot/bootmgfw.efi:Windows Boot Manager:Windows1:efi
/dev/nvme0n1p1
is my fedora system partition.
/dev/sda1
is on a separate drive where the windows system is installed.
The entry for /dev/sda1
is the correct one, whilst the one for /dev/nvme0n1p1
causes an error. I imagine this was somehow left over from a previous install.
I would like to remove the erroneous entry from the boot menu to stop anyone from accidentally choosing it.
I have searched extensively and read what I could to try and figure out what to do but the GRUB2 docs at https://docs.fedoraproject.org/en-US/quick-docs/grub2-bootloader/ were last reviewed in 2012 and I don’t know if the information in them is still valid. I am concerned about doing anything which would potentially stop the windows system from booting at all.
I can see that the boot files are duplicated:
Incorrect entry:
$ sudo ls -lahF /boot/efi/EFI/Microsoft/Boot
total 5.8M
drwx------. 40 root root 8.0K Mar 12 2023 ./
drwx------. 4 root root 4.0K Mar 12 2023 ../
-rwx------. 1 root root 40K Jul 21 15:49 BCD*
-rwx------. 1 root root 64K Mar 12 2023 BCD.LOG*
-rwx------. 1 root root 0 Mar 12 2023 BCD.LOG1*
-rwx------. 1 root root 0 Mar 12 2023 BCD.LOG2*
drwx------. 2 root root 4.0K Mar 12 2023 bg-BG/
-rwx------. 1 root root 1.5M Oct 6 2021 bootmgfw.efi*
-rwx------. 1 root root 1.5M Oct 6 2021 bootmgr.efi*
-rwx------. 1 root root 64K Mar 12 2023 BOOTSTAT.DAT*
-rwx------. 1 root root 5.1K Oct 6 2021 boot.stl*
<snip>
And with /dev/sda1
mounted as /windows/bootefi
:
Correct entry:
$ sudo ls -lahF /windows/bootefi/EFI/Microsoft/Boot/
total 6.0M
drwxr-xr-x. 40 root root 5.0K Mar 12 2023 ./
drwxr-xr-x. 4 root root 1.0K Mar 12 2023 ../
-rwxr-xr-x. 1 root root 44K Jul 22 22:24 BCD*
-rwxr-xr-x. 1 root root 64K Mar 12 2023 BCD.LOG*
-rwxr-xr-x. 1 root root 0 Mar 12 2023 BCD.LOG1*
-rwxr-xr-x. 1 root root 0 Mar 12 2023 BCD.LOG2*
drwxr-xr-x. 2 root root 1.0K Mar 12 2023 bg-BG/
-rwxr-xr-x. 1 root root 1.6M Jul 9 20:17 bootmgfw.efi*
-rwxr-xr-x. 1 root root 1.6M Jul 9 20:17 bootmgr.efi*
-rwxr-xr-x. 1 root root 64K Jul 9 22:54 BOOTSTAT.DAT*
-rwxr-xr-x. 1 root root 11K Apr 9 22:40 boot.stl*
<snip>
I am happy to just ignore the files at /boot/efi/EFI/Microsoft/Boot
(unless there is some reason why I should rather remove them) though as mentioned, I do want to remove the grub menuentry.
I would be grateful for info on how to safely remove this grub entry whilst ensuring that I can continue to boot the windows system at /dev/sda1
.
Thanks for any help.