Windows – Boot Ubuntu VHDX alongside Windows 10

bootboot-to-vhdUbuntuwindows 10

I have a Windows 10 installation on my Lenovo T430s laptop. I would like to dual boot into an Ubuntu 14.04 VHDX at startup that was created using Hyper-V (running on the same laptop). The Ubuntu instance runs perfectly if I run it as a VM on Hyper-V within Windows 10.

I have followed the instructions details here and have edited my boot configuration using bcdedit (full configuration show at the bottom of this question).

When I come to select the Operating System to boot from at startup, I am correctly presented with my choice of two OS's: Windows 10 or Ubuntu, but here is my problem: if I select Ubuntu, the laptop restarts back into Windows 10.

So, how do I get the laptop to restart into Ubuntu (and not Win10) when I select Ubuntu as the OS to boot?

Ideally, I would like to native-boot the VHDX, rather than install a different boot-loader.

Finally, in case you're wondering why I'm doing this – I want to put Ubuntu Touch onto a legacy Nexus tablet and I can't get access to the physical USB hub to flash the device from Ubuntu when I run it on Windows 10 in Hyper-V. Bummer.

Output from bcdedit:

C:\WINDOWS\system32>bcdedit

Windows Boot Manager
--------------------
identifier              {bootmgr}
device                  partition=\Device\HarddiskVolume1
description             Windows Boot Manager
locale                  en-US
inherit                 {globalsettings}
flightsigning           Yes
default                 {current}
resumeobject            {47306ac4-7ae2-11e5-a36c-8c29a9f075ab}
displayorder            {current}
                        {62103dd7-37a6-11e5-8e2f-8459cfd235f7}
toolsdisplayorder       {memdiag}
timeout                 5

Windows Boot Loader
-------------------
identifier              {current}
device                  partition=C:
path                    \WINDOWS\system32\winload.exe
description             Windows 10
locale                  en-US
inherit                 {bootloadersettings}
recoverysequence        {8ac3ce47-7ae2-11e5-a36c-8c29a9f075ab}
recoveryenabled         Yes
flightsigning           Yes
allowedinmemorysettings 0x15000075
osdevice                partition=C:
systemroot              \WINDOWS
resumeobject            {47306ac4-7ae2-11e5-a36c-8c29a9f075ab}
nx                      OptIn
bootmenupolicy          Standard
hypervisorlaunchtype    Auto

Windows Boot Loader
-------------------
identifier              {62103dd7-37a6-11e5-8e2f-8459cfd235f7}
device                  vhd=[locate]]\Virtual Hard Disks\Ubuntu.vhdx
path                    \Windows\system32\winload.exe
description             Ubuntu
locale                  en-US
inherit                 {bootloadersettings}
recoverysequence        {62103dd5-37a6-11e5-8e2f-8459cfd235f7}
recoveryenabled         Yes
flightsigning           Yes
allowedinmemorysettings 0x15000075
osdevice                vhd=[locate]\Virtual Hard Disks\Ubuntu.vhdx
systemroot              \Windows
resumeobject            {62103dd3-37a6-11e5-8e2f-8459cfd235f7}
nx                      OptIn
bootmenupolicy          Standard
hypervisorlaunchtype    Auto

Best Answer

This is an old question which remained unanswered and I googled it out while looking for solution to similar problem. Answer is below to help others who will find it.

It is possible to boot from VHD linux file on systems with windows 32 bit or 64 bit installed. There is an old solution created by VMLite VBoot. However it does require installation of some additional software (may be downloaded from VMLite) and specially modified VHD file. Supported systems: Windows 2000, XP, 2003, Vista, 2008, Windows 7, 2008 R2, 32- and 64- bits, all service packs and editions but I would suppose Windows 10 would work as well.

There is no info on how to use VHDX format but I would expect it may not work without modification of VBoot code. Most probably VBoot does what Windows devs did in windows to boot windows from VHD - create binary boot code that understands VHD file format and presents it to the system during boot as disk partition.

VBoot and VMLite site seems to be not very active so proceed with caution.

Related Question