Failed to start the virtual machine 'MobyLinuxVM' because one of the Hyper-V components is not running

巧了我就是萌 提交于 2019-11-28 17:51:26

In case this helps anyone else getting this issue, I found that running these commands from an admin command prompt fixed my Hyper-V issue:

net stop vmms 
net start vmms

I then was able to start my docker container without issue.

Here is a solution if you are getting this error on Azure Windows 10 VM where you have installed Docker:

  • Ensure Windows Hyper-V featutes are enabled by running PowerShell cmdlet:

Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V -All -Verbose

  • Ensure Windows Containers feature is enabled by running PowerShell cmdlet:

Enable-WindowsOptionalFeature -Online -FeatureName Containers -All -Verbose

  • Ensure Hypervisor is set to auto start in the Boot Configuration Database (BCD) by running in elevated command prompt the command:

bcdedit /set hypervisorlaunchtype Auto

After running all of the above and you restart the Azure VM, Docker should be starting normally.

In addition to the Answer above the PowerShell cmdlet to set the Virtual Machine Setting is:

Set-VMProcessor -VMName <Enter-VM-Name> -ExposeVirtualizationExtensions $true -Verbose

Still have an issue and haven't rebooted yet?! - just restart the windows services by running the following:

net stop vmms 
net start vmms

Hi all I have found the answer to deal with this problem hopefully this content can help someone who has the same issue.
1. to setup VM at Virtual Machine Settings (like as following picture)

  1. to setup the Hyper-V in the Windows Server 2016 (like as following picture)

Mandarin reference URL

Akash Srivastava
  1. Open up a PowerShell or CMD session as Administrator.

  2. Type the following command:

    Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V -All
    
Luis Cunha

I went to docker settings and in General section selected to install the other version (bottom of the page as link). I initially installed the stable, changed for beta / edge.

That worked without any issues.

BugsFindMe

This is a nested virtualization issue to fix it running VMWare 6.5 and Windows 10 guest turn off the VM and select the option to Expose hardware assisted virtualization to the guest OS.

These steps worked for me in Windows 10 Pro v1809. First, close Docker error window. Then

Start > Windows Security app > App & browser control > Exploit Protection > Exploit protection settings > Program settings > vmcompute.exe > Edit > Code flow guard (CFG) >

Uncheck "Override system settings" > Apply

In elevated (i.e. Run As Administrator) cmd window start service with

net start vmcompute

Then start Docker Desktop again, should start this time

Actualy the reason is you have not enabled ExposeVirtualizationExtensions on host.
Shut down nested VM. Run PS command on host:

Set-VMProcessor -VMName "NESTED VM NAME" -ExposeVirtualizationExtensions $true

And then start nested VM (with docker in it) again.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!