网站更新内容:请访问: https://bigdata.ministep.cn/

docker-desktop: exit code: -1

[(37条消息) 基于WSL2 的 Docker Desktop 启动时 Failed to set version to docker-desktop: exit code: -1的解决方法_qhd1994的博客-CSDN博客](https://blog.csdn.net/qhd1994/article/details/111831427)

 

在Windows 10 的 2004 版本  中, 启用 使用Docker Desktop 时 发现  根本无法启动, 偶尔或者频繁的出错:

  1.  
    System.InvalidOperationException:
  2.  
    Failed to set version to docker-desktop: exit code: -

 

  1.  
    System.InvalidOperationException:
  2.  
    Failed to set version to docker-desktop: exit code: -
  3.  
     
  4.  
    stderr: 
  5.  
       在 Docker.ApiServices.WSL2.WslShortLivedCommandResult.LogAndThrowIfUnexpectedExitCode(String prefix, ILogger log, Int32 expectedExitCode) 位置 C:\workspaces\PR-15077\src\github.com\docker\pinata\win\src\Docker.ApiServices\WSL2\WslCommand.cs:行号 146
  6.  
       在 Docker.Engines.WSL2.WSL2Provisioning.<ProvisionAsync>d__8.MoveNext() 位置 C:\workspaces\PR-15077\src\github.com\docker\pinata\win\src\Docker.Desktop\Engines\WSL2\WSL2Provisioning.cs:行号 82
  7.  
    --- 引发异常的上一位置中堆栈跟踪的末尾 ---
  8.  
       在 System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
  9.  
       在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  10.  
       在 Docker.Engines.WSL2.LinuxWSL2Engine.<DoStartAsync>d__25.MoveNext() 位置 C:\workspaces\PR-15077\src\github.com\docker\pinata\win\src\Docker.Desktop\Engines\WSL2\LinuxWSL2Engine.cs:行号 99
  11.  
    --- 引发异常的上一位置中堆栈跟踪的末尾 ---
  12.  
       在 System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
  13.  
       在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  14.  
       在 Docker.ApiServices.StateMachines.TaskExtensions.<WrapAsyncInCancellationException>d__0.MoveNext() 位置 C:\workspaces\PR-15077\src\github.com\docker\pinata\win\src\Docker.ApiServices\StateMachines\TaskExtensions.cs:行号 29
  15.  
    --- 引发异常的上一位置中堆栈跟踪的末尾 ---
  16.  
       在 System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
  17.  
       在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  18.  
       在 Docker.ApiServices.StateMachines.StartTransition.<DoRunAsync>d__5.MoveNext() 位置 C:\workspaces\PR-15077\src\github.com\docker\pinata\win\src\Docker.ApiServices\StateMachines\StartTransition.cs:行号 67
  19.  
    --- 引发异常的上一位置中堆栈跟踪的末尾 ---
  20.  
       在 System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
  21.  
       在 Docker.ApiServices.StateMachines.StartTransition.<DoRunAsync>d__5.MoveNext() 位置 C:\workspaces\PR-15077\src\github.com\docker\pinata\win\src\Docker.ApiServices\StateMachines\StartTransition.cs:行号 92

启动 WSL 2时警告“参考的对象类型不支持尝试的操作”

管理员方式执行cmd命令  

 netsh winsock reset  

 

然后启动  docker-desktop 

转载csdn博文:

https://blog.csdn.net/MShow006/article/details/103774672

https://blog.csdn.net/mysticboy/article/details/106632922

posted @ 2022-07-05 22:17  ministep88  阅读(656)  评论(0编辑  收藏  举报
网站更新内容:请访问:https://bigdata.ministep.cn/