For Hyper-V virtual machines to run, hypervisor needs to be started before Windows kernel. This means that turning it on or off
always requires a restart.
You can add a boot menu option to turn hypervisor on when you need it by modifying Windows boot records. Open an
elevated Command Prompt and enter following command to copy current boot configuration to boot menu entry
Hypervisor ON:
bcdedit /copy {current} /d "Hypervisor ON"
This adds a new default boot configuration with identifier
{default}.
Next, make the new default boot configuration to turn hypervisor on with following command:
bcdedit /set {default} hypervisorlaunchtype auto
Default OS or boot configuration will be booted if user makes no selection in given timeframe, by default 30 seconds. As you would not want your new
Hypervisor ON boot configuration being default, move it to last item on boot menu:
bcdedit /displayorder {default} /addlast
To be sure that your original boot configuration boots to Windows without hypervisor, enter following command:
bcdedit /set {current} hypervisorlaunchtype off
Now you will be shown a boot menu every time you boot computer. Select
Windows 10 if you want to boot without hypervisor, or select
Hypervisor ON when you need Hyper-V.
Kari
EDIT:
Forgot to add screenshot of boot menu created with commands in this post: