1

I have been looking for a solution to my problem in this forum and elsewhere but could not really find one (that does not appear unpredictable or even dangerous).

My Problem:

When trying to create a bootable USB stick with a fully installed Ubuntu on my work computer, I accidentally installed the GRUB bootloader on the company laptop (instead of the USB drive). So now when I switch on the laptop (without the drive of course) it only show a GRUB prompt:

GNU GRUB version 2.04
Minimal BASH-like line editing is supported. For the first word, TAB lists possible command completions.
Anywhere else TAB lists possible device or file completion.
Grub> _

Bad, very bad. (And, yes, I know, very, very stupid.)

I have found instructions on how to remove GRUB from a Windows only system using Windows. That, however, I cannot do, since I don't have Administrator privileges in Windows.

Therefore the only thing I can do is boot the system from a Ubuntu pendrive and try to solve it from there.

Plus, I cannot tinker and try out things since I cannot afford to damage things even further (as of now the Laptop at least still works: when I press F9 for the boot menu, I can start Windows).

Can anybody help me, please?

Anna
  • 11
  • If the laptop has [only] windows on it; I'd perform the fix using windows, be it from the installed OS, or using windows installation/repair media. – guiverc Mar 11 '22 at 08:23
  • You have solve it via a windows repair medium; Ubuntu cannot install a Windows Boot Manager, which is not open-source and Ubuntu cannot install it. – Emoji Mar 11 '22 at 08:32
  • bootrec and fixboot commands from a windows installation or rescue media. – mchid Mar 11 '22 at 08:49
  • Thank you all for replying so quickly! Unfortunately, method 1 of the tutorial Emoji recommended did not work: the application says it "diagnoses" and then concludes that it could not repair the PC. Does "bootrec and fixboot commands from a windows installation or rescue media" mean that I use method 2 of Emoji's tutorial? https://www.easeus.com/partition-manager-software/fix-uefi-boot-in-windows-10-8-7.html#1 – Anna Mar 11 '22 at 09:26
  • First things first, can you access uEFI ("BIOS") settings (F10), it isn't password protected? If so just go to the Boot menu and change the boot order back to Windows. This should make Windows boot directly, indistinguishable from like it was before, but it won't remove the Grub entry. – ChanganAuto Mar 11 '22 at 13:23
  • You normally only can change boot order in UEFI settings, not UEFI menu. You can use efibootmgr to change boot order from Ubuntu and mount the ESP - efi system partition and remove /EFI/ubuntu folder. Uninstall Ubuntu from menu, Really UEFI boot menu http://askubuntu.com/questions/63610/how-do-i-remove-ubuntu-in-the-bios-boot-menu-uefi & https://askubuntu.com/questions/429610/uninstall-grub-and-use-windows-bootloader
    If installing to external drive see this and ask in another question: https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/1396379
    – oldfred Mar 11 '22 at 13:33
  • Changing the boot order did not help (I did it via efibootmgr). I still got that black GRUB screen when starting the laptop. The only difference was that Ubuntu had moved from the first to the last place in the boot menu and Windows had moved to the first. Thank you, oldfred, your links showed the way how to proceed further. – Anna Mar 11 '22 at 21:02

2 Answers2

0

In short: Ubuntu doesn't help.

Ubuntu cannot install a Windows Boot Manager, of course. So you have to create a Windows repair medium, boot into it, and fix your bootloader there. You can refer to the method 1 of this tutorial.

As your Ubuntu on your thumb drive is entirely new and can be assumed that there are no data, you can just reinstall Ubuntu on your thumb drive. Be careful this time!

Emoji
  • 577
  • Thank you, Emoji! Unfortunately, that did not do the trick (see comment above) for some reason. Should I proceed to method 2 or is that futile if method 1 ended with the info that it "could not repair PC"? – Anna Mar 11 '22 at 10:04
  • If I have to proceed to method 2: The tutorial says "UEFI partition will be on Volume 2." In my case however, Volume 2 appears to be the USB drive (Vol 0 NFTS,476 GB, VOL 1 FAT32, 260 MB, Vol 2 RAW, 232 GB). I guess the UEFI partition would then be VOL 1 since its FAT32 and small, right? – Anna Mar 11 '22 at 10:10
0

Thank you all!

In the end it was a combination of all your suggestions that did the trick.

This is what I did:

  1. Create a Windows installation medium

  2. Boot from that USB stick

  3. Choose "Repair your computer"/"Troubleshoot"/"Command Prompt"

  4. Follow these instructions minutely

Problem solved. Again: Thank you!

p.s. I am really impressed by this forum. The speed and competence of the answers I got is probably unique (or at least exceptional).

Anna
  • 11