问题
I have got some problem when I installed Docker with Window Server.
The environment list:
1 Windows 10 (Physical Machine)
2.VMware® Workstation Player (12~ above) URL
3.Windows Server 2016 at the VM
4.Docker CE for Windows(stable) URL
the problem picture and content
Unable to start: The running command stopped because the preference variable "ErrorActionPreference" or common parameter is set to Stop: 'MobyLinuxVM' failed to start.
Failed to start the virtual machine 'MobyLinuxVM' because one of the Hyper-V components is not running.
'MobyLinuxVM' failed to start. (Virtual machine ID BBD755F7-05B6-4933-B1E0-F8ACA3D2467B)
The Virtual Machine Management Service failed to start the virtual machine 'MobyLinuxVM' because one of the Hyper-V components is not running (Virtual machine ID BBD755F7-05B6-4933-B1E0-F8ACA3D2467B).
at Start-MobyLinuxVM, <No file>: line 315
at <ScriptBlock>, <No file>: line 410
at Docker.Backend.ContainerEngine.Linux.DoStart(Settings settings, String daemonOptions) in C:\gopath\src\github.com\docker\pinata\win\src\Docker.Backend\ContainerEngine\Linux.cs:line 256
at Docker.Backend.ContainerEngine.Linux.Start(Settings settings, String daemonOptions) in C:\gopath\src\github.com\docker\pinata\win\src\Docker.Backend\ContainerEngine\Linux.cs:line 130
at Docker.Core.Pipe.NamedPipeServer.<>c__DisplayClass9_0.<Register>b__0(Object[] parameters) in C:\gopath\src\github.com\docker\pinata\win\src\Docker.Core\pipe\NamedPipeServer.cs:line 47
at Docker.Core.Pipe.NamedPipeServer.RunAction(String action, Object[] parameters) in C:\gopath\src\github.com\docker\pinata\win\src\Docker.Core\pipe\NamedPipeServer.cs:line 145
How can I fix this problem issue,Thanks.
回答1:
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.
回答2:
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
回答3:
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)
- to setup the Hyper-V in the Windows Server 2016 (like as following picture)
Mandarin reference URL
回答4:
Open up a PowerShell or CMD session as Administrator.
Type the following command:
Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V -All
回答5:
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.
回答6:
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.
回答7:
Enabling Hyper-V feature is not enough in Azure VM. You have to have "Nested virtualization" enabled, so according to documentation you should choose v3
sized VM:
all v3 virtual machines support nested virtualization
After resizing, VM will be restarted and DockerVM in Hyper-V will run.
回答8:
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
回答9:
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.
来源:https://stackoverflow.com/questions/48255871/failed-to-start-the-virtual-machine-mobylinuxvm-because-one-of-the-hyper-v-com