WSL Ubuntu bash:操作超时,因为未收到来自虚拟机或容器的响应

use*_*755 1 bash ubuntu windows-subsystem-for-linux wsl2

我使用的是 Windows 10 Pro 10.0.21337(Windows Insider 程序)并在 Ubuntu 和 Windows 终端上安装了 WSL。固件更新后,ubuntu bash 将不再启动。在 cmd.exe 中,响应是:

The operation timed out because a response was not received from the virtual machine or container.
Run Code Online (Sandbox Code Playgroud)

我在 www 上的几页中发现了这条消息,但它们主要与 docker 容器有关。

小智 7

比完全重启 PC 更快的解决方案是运行:

wsl --shutdown
Run Code Online (Sandbox Code Playgroud)

...这将仅重新启动 WSL 服务。

  • 是的,这很有效。 (2认同)
  • 这也解决了我在 Windows 11 升级后出现的超时问题。 (2认同)

use*_*755 2

这个问题的症状有点不同,但它的解决方案解决了这个问题:完全重新启动Windows10,按住shift键打开Windows>开始菜单>电源>重新启动。