当前位置:   article > 正文

windows11启动docker报错:Docker Desktop - Unexpected WSL error_.g. running wsl --shutdown). restart docker deskto

.g. running wsl --shutdown). restart docker desktop. if the issue persists,

问题描述

windows11启动docker(版本为4.26.1)报错:

Docker Desktop - Unexpected WSL error
An unexpected error was encountered while executing a WSL command. Common
causes include access rights issues, which occur after waking the computer or not
being connected to your domain/active directory.
Please try shutting WSL down (wsl -shutdown) and/or rebooting your computer. If
not sufficient, WSL may need to be reinstalled fully. As a last resort, try to
uninstall/reinstall Docker Desktop. If the issue persists please collect diagnostics and
submit an issue
…://docs.docker.com/desktop/troubleshoot/overview/#diagnose-from-the-terminal).

报错原因

wsl环境指定没有成功,就是wsl没有被成功转换为wsl2版本,执行wsl --set-version Ubuntu-20.04 2报错如下:

被这个问题卡了一周,试遍了docker社区的各种解决方案都不行,终于一步步试出了解决方案。

解决方案

启用或者关闭windows功能里面取消勾选“windows虚拟机监控程序平台”,是取消勾选。网上自己能找到的该问题的解决方案没有一个说要取消勾选的。

重启电脑,重新执行wsl --set-version Ubuntu-20.04 2命令。启动docker,一切正常。

声明:本文内容由网友自发贡献,转载请注明出处:【wpsshop】
推荐阅读
相关标签
  

闽ICP备14008679号