小编Kai*_*igo的帖子

WSL2 无法在 Windows 11 上访问互联网

我全新安装了 Windows 11,并在 wsl2 内安装了 ubuntu 20.04。

当我尝试执行更新sudo apt update甚至ping google.com我得到

暂时无法解析“archive.ubuntu.com”

名称解析暂时失败

分别出现错误。

我试过了:

  • 使用“允许应用程序通过防火墙”并选择允许 wsl 通过 Windows firefallC:\Windows\System32\wsl.exe

  • 在防火墙中添加端口 3390 的入站规则

  • 将网络配置文件设置为“私有”(尽管如果有办法让 wsl 正常工作,我更愿意将其保持公开)

  • New-NetFirewallRule -DisplayName "WSL" -Direction Inbound -InterfaceAlias "vEthernet (WSL)" -Action Allow从谷歌搜索运行

编辑:此时我已经尝试了所有谷歌结果,但仍然没有解决方案。r/windows11 不会让我发帖,除非是星期一(愚蠢)。还尝试在 wsl 上重新安装 ubuntu,但无济于事。

windows-subsystem-for-linux

8
推荐指数
1
解决办法
3万
查看次数

标签 统计

windows-subsystem-for-linux ×1