Problem with VirtualBox 5.x running on GNU/Linux Debian 9.x host:

EFI-enabled guest suddenly boots only into UEFI Interactive Shell.

UEFI Interactive Shell

It waits for 5 seconds and then it drops to Shell>.

I don't remember any modifications, which I would have done, neither to the host, nor guest, or VirtualBox itself.


Plausible fix:

  1. In UEFI Interactive Shell, enter the file system:

  2. Following up with creating this file:

    edit startup.nsh
  3. Enter this or similar line to it:

  4. Press CTRL+S to save the file.

  5. Press ENTER to confirm the file name.

  6. Press CTRL+Q to exit the editor.

  7. Restart the Guest:


Important notes:

  1. For some reason you have only a few seconds to edit and save the file. If it takes you longer, then the guest may react with a significant delay. Or it may even freeze.

  2. Replace debian with your system's id, e.g. ubuntu. You may verify this by simply going into the \EFI\ directory and running ls.

Another way:

If you don't succeed, and supposing your guest is Linux type, I myself had to do it:

  1. Boot from live USB with any Linux.

  2. Mount the root file system.

  3. Create this file on the mounted file system, adjust the path to wherever you have mounted it:

  4. Enter the above explained line to it.



In the VirtualBox settings for your VM, go to System settings and in the Motherboard section un-check the

Enable EFI (Special OSes only).

Save the settings and restart your VM.

Important notes:

  1. This will make the guest system run on BIOS / MBR legacy boot.

  2. Only use, if the solution above does not work for you.

  • Yes, thank you! It was necessary to Enable EFI in order to make the GParted Live CD work. However, after resizing the disk partitions in GParted, I encountered this error, and also an error "fs0 is not a correct mapping" if I tried to enter the file system. Disabling this flag solved issue. – Jamie Oct 25 '18 at 5:35
  • But how do I shutdown virtual machine? – Nilesh Apr 8 at 7:21

I had this come-up today. In my case, I had selected "Enable EFI" on the Settings: System panel, on the Motherboard tab. That was conscious because the drive I wanted to boot from wasn't (booting).

This can be removed by unchecking the check-box.

While it looks useful, it is very frustrating so I advise people to open a web page with the help outpur on show. All the commands scroll off the screen before you have a chance to read them. And there is no less or more command.

protected by Community Feb 3 at 14:51

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.