1

I am trying to use grub-reboot to boot just once to Windows (following this post).

Strangely enough, using the auto-completion from grub-reboot (or awk -F\' '/menuentry / {print $2}' /boot/grub/grub.cfg from this post,) I only see Ubuntu entries, or the last one UEFI Firmware Settings. Am I not supposed to see the Windows entry listed? How would I then boot to Windows at next restart?

Here is the output from awk -F\' '/menuentry / {print $2}' /boot/grub/grub.cfg:

Ubuntu
Ubuntu, with Linux 5.4.0-54-generic
Ubuntu, with Linux 5.4.0-54-generic (recovery mode)
Ubuntu, with Linux 5.4.0-53-generic
Ubuntu, with Linux 5.4.0-53-generic (recovery mode)
Ubuntu, with Linux 5.4.0-52-generic
Ubuntu, with Linux 5.4.0-52-generic (recovery mode)
UEFI Firmware Settings
Matifou
  • 708
  • 1
  • 7
  • 24

1 Answers1

2

Since you use UEFI, you can make use of it's next-boot-feature.

All you need is the efibootmgr-command. Use

efibootmgr -v

to see the list of your boot entries. Then choose the entry for the next boot with

sudo efibootmgr -n XXXX

where XXXX is the number of the desired entry from the list.

reboot
mook765
  • 15,925
  • Thanks! I see BootOrder: 0001,0000 and Boot0000* Windows Boot Manager so 0000 will be the number, right? And also this is just for one reboot, right? Thanks! – Matifou Nov 30 '20 at 01:47
  • Yes, that's correct. – mook765 Nov 30 '20 at 08:39
  • Thanks! My initial problem is that my laptop screen is broken and I don't see the GRUB menu. Setting efibootmgr to Windows Boot Manager still results into a black screen with nothing happening (as does choosing Rescue and Recovery or Lenovo Diagnostics), which could be due to the menu being shown but waiting for an input I can't see. Is there a more direct way to say I want to boot into the Windows first option? Thanks! – Matifou Nov 30 '20 at 18:56
  • 1
    No, it's the same as if you would use the built in efi boot menu and choose Windows from there. Broken hardware should be repaired or replaced. – mook765 Dec 01 '20 at 00:43