更新WSL:wsl --update --pre-release 在用户目录%USERPROFILE%下面创建一个配置文件.wslconfig,写入以下内容: [experimental] networkingMode=mirrored dnsTunneling=true firewall=true autoProxy=true 如果你遇到 docker 无法从 Windows 访问的问题,这个是 iptables 的问题,在/etc/docker/daemon.json里添加一句"iptabl...
更新系统版本到 23H2 (目前还没发正式版,可以考虑加入 Windows Insider 的Release Preview 或者 Beta 预览版通道)。或者如果不想加入预览版计划的话你也可以等几周,23H2 也快发布正式版了。 wsl --update --pre-release 把WSL2 更新到 2.0.0 或以上版本 在%userprofile%\.wslconfig 中写入以下内容然后保存:...
wsl --update --pre-release 之后,使用 windows 的账号连接 windows 的 ssh,即可远程 wsl 服务了。 如果嫌启动 wsl 麻烦,可以再做一个配置,直接把 ssh 的终端设置为 wsl New-ItemProperty -Path "HKLM:\SOFTWARE\OpenSSH" -Name DefaultShell -Value "C:\Windows\System32\wsl.exe" -PropertyType String -...
2.5.4Pre-release Fix the wsl --update --pre-release logic to correctly handle backports and always pick the actual latest Set LX_WSL2_INSTALL_PATH even when gui apps are disabled Introduce general.instanceIdleTimeout to control distribution termination timeouts (solves#10138,#9401) ...
现在不用手动开关了 修改一下.wslconfig文件就能自动开启代理了,以下是我的配置文件,修改前需要在powershell运行 wsl --update --pre-release```[wsl2]nestedVirtualization=trueipv6=true[experimental]autoMemoryReclaim=gradual # gradual | dropcache | disablednetworkingMode=mirroreddnsTunneling=truefirewall=true...
If you prefer not switching your Windows installation to a preview channel, you can still test the latest preview of WSL by issuing the command:wsl --update --pre-release. For more information check theWSL Releases page on GitHub. Additional resources ...
# PowerShellwsl--updatewsl--update--pre-release 1. 2. 3. 配置 .wslconfig使用 VSCode(或任何您喜欢的编辑器)再次打开文件 # PowerShellcode .wslconfig 1. 2. 并设置实验标志(根据您的需要)。例如: [experimental]# Automatic memory reclaimautoMemoryReclaim=gradual# Automatic disk space clean upsparse...
If you prefer not switching your Windows installation to a preview channel, you can still test the latest preview of WSL by issuing the command:wsl --update --pre-release. For more information check theWSL Releases page on GitHub. Additional resources ...
wsl 升级到 2.x 需要 Win 11 专业版的 23H2 版本,升级命令:wsl --update --pre-release 5.2:配置 配置镜像网络后,只能通过 127.0.0.1 访问,避免过度占用宿主机端口,其它 IP 需配置 hostAddressLoopback 参数。 编辑%USERPROFILE%路径下的.wslconfig文件 (没有就创建),添加以下配置: ...
升级WSL至最新版本2.0.0(可能需要预发布版本)是另一个可能的解决方案,因为2.0.0引入了新的镜像网络来解决网络问题。通过运行`wsl --update --pre-release`进行更新。尽管有相关推荐,但值得注意的是,升级到Windows 11可能也无法立即解决问题,可能需要进一步测试。以上步骤有助于你逐步排查并解决...