Debian VM in efi-mode boot iso

Discussions about using Linux guests in VirtualBox.
Post Reply
FX8370core
Posts: 10
Joined: 16. Feb 2021, 20:54

Debian VM in efi-mode boot iso

Post by FX8370core »

Got a working VM with a Debian installation in efi-mode. This VM always starts the installation no matter if an iso is connected to the CD drive, and how the boot order is set. On a native PC you have a boot override option.

Is there such an option for an efi VM?

BTW: in legacy installs booting from an attached iso works fine.

Thanks, FX
scottgus1
Site Moderator
Posts: 20371
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: Debian VM in efi-mode boot iso

Post by scottgus1 »

You can change the boot order of an EFI VM by tapping ESC as the VM boots, or typing exit at the EFI command prompt. Either will take you to the black-on-gray EFI menu, where you can pick the boot source. (EFI does not acknowledge the Boot Order in the VM's System settings Motherboard tab, nor does it work with Legacy BIOS's F12.)

However:
FX8370core wrote: 22. Sep 2023, 16:15 This VM always starts the installation no matter if an iso is connected to the CD drive
The way this is worded, the VM always goes to the OS installer that is seen when booting from the ISO, even if an ISO is not in the VM's Optical drive, which is very weird. Is this what you meant?
FX8370core
Posts: 10
Joined: 16. Feb 2021, 20:54

Re: Debian VM in efi-mode boot iso

Post by FX8370core »

Thanks, if I am fast enough the ESC key brings the grey efi menu, and I can select the iso attached for booting.

When I am not fast enough the VM boots into the Debian on the virtual hard disk. That what I meant with the "installation" (that was finished already).

My goal is to overwrite the VM.
scottgus1
Site Moderator
Posts: 20371
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: Debian VM in efi-mode boot iso

Post by scottgus1 »

OK, makes sense. ESC is the way to go, then.

Another way to overwrite the VM, if you're starting from absolute scratch without any partitioning on the VM's disk, is to make a fresh new disk and swap it in place of the previously installed disk. Then the VM will not find an already-installed OS and should fall back to the ISO.
Post Reply