我在Windows 10专业版PC上设置Docker时遇到了一些问题.当我尝试打开它时,我得到了这个崩溃报告:
您会看到Debian/Ubuntu/kali-linux的版本设置为2.
但是docker-desktop也在使用版本2.
我的解决方法是
..我知道这不是一个好消息,但这是我如何解决的.
将WSL2降级为WSL1将无济于事.
I have had some problems with setting up Docker on my Windows 10 pro PC. I get this crash report when I try to open it up:
This is the text that is inside of the box:
System.InvalidOperationException:
Failed to deploy distro docker-desktop to C:\Users\Imogen\AppData\Local\Docker\wsl\distro: exit code: -1
stdout: Access is denied.
stderr:
at Docker.ApiServices.WSL2.WslShortLivedCommandResult.LogAndThrowIfUnexpectedExitCode(String prefix, ILogger log, Int32 expectedExitCode) in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.ApiServices\WSL2\WslCommand.cs:line 146
at Docker.Engines.WSL2.WSL2Provisioning.<DeployDistroAsync>d__17.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.Desktop\Engines\WSL2\WSL2Provisioning.cs:line 169
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Docker.Engines.WSL2.WSL2Provisioning.<ProvisionAsync>d__8.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.Desktop\Engines\WSL2\WSL2Provisioning.cs:line 78
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Docker.Engines.WSL2.LinuxWSL2Engine.<DoStartAsync>d__25.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.Desktop\Engines\WSL2\LinuxWSL2Engine.cs:line 99
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Docker.ApiServices.StateMachines.TaskExtensions.<WrapAsyncInCancellationException>d__0.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.ApiServices\StateMachines\TaskExtensions.cs:line 29
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Docker.ApiServices.StateMachines.StartTransition.<DoRunAsync>d__5.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.ApiServices\StateMachines\StartTransition.cs:line 67
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at Docker.ApiServices.StateMachines.StartTransition.<DoRunAsync>d__5.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.ApiServices\StateMachines\StartTransition.cs:line 92
I have checked my visualization settings and it is enabled. My BIOS is legacy, not sure if UEFI Firmware settings are needed for Docker. My Hyper-V is also enabled in Windows Features. I have also been accessing docker with an authorized cmd. Any advice or suggestions will be much appreciated!
This is happening because there is an incompatibility between WSL2 and Docker.
If you run wsl -l -v
I'm quite sure you will see this:
As you can see the VERSION for Debian/Ubuntu/kali-linux is set to 2.
But also docker-desktop is using version 2.
My solution was to
..I know this is not a good news but this is how I fixed it.
Downgrading WSL2 to WSL1 won't help.
这篇关于我的Docker无法在Windows 10 Pro上启动的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程技术网(www.editcode.net)!