please restart WSL with the following command and try again

please restart WSL with the following command and try again:
wsl --shutdown
wsl --unregister DISTRO_NAME 

解决方法

  1. 造成该问题的原因是WSL版本由原来的WSL1升级到WSL2后,内核没有升级,前往微软WSL官网下载安装适用于 x64 计算机的最新 WSL2 Linux 内核更新包即可。
  • 下载地址:https://wslstorestorage.blob.core.windows.net/wslblob/wsl_update_x64.msi

安装完成,再次打开就正常启动了。

  1. 如果不想安装WSL2 ,可以切换使用命令wsl -set-default-version 1,切换到 WSL1