1.4 KiB
1.4 KiB
title, type, tags, sources, last_updated
| title | type | tags | sources | last_updated | ||
|---|---|---|---|---|---|---|
| WSL2 | entity |
|
2026-04-17 |
基本信息
- 全称:Windows Subsystem for Linux 2
- 类型:产品 / 开发工具
- 官方文档:https://docs.microsoft.com/windows/wsl/
说明
WSL2 是 Microsoft 官方提供的 Windows 内置 Linux 运行环境,基于完整 Linux 内核(WSL1 为翻译层),默认使用 NAT 网络模式。Windows 10/11 Build 19041+ 可通过 wsl --install 一键安装。
核心特性
- 完整 Linux 内核:WSL2 使用真实 Linux 内核,支持系统调用兼容
- NAT 网络模式(默认):WSL2 有独立 IP,与 Windows 主机网络隔离
- 镜像网络模式(推荐):通过
.wslconfig配置networkingMode=mirrored+dnsTunneling=true使 WSL2 与 Windows 共享网络堆栈 - 跨文件系统:Windows 驱动器挂载在
/mnt/c/下
相关工具
- uv:Python 包管理工具,可通过
ghproxy.com镜像加速安装 - Hermes Agent:可通过
ghproxy.com镜像地址安装
来源
Connections
- WSL2 ← depends_on ← Install WSL(先安装后配置)
- WSL2 ← uses ← ghproxy(通过反向代理加速下载)
- WSL2 ← related_to ← Ubuntu Server(均为 Linux 环境,WSL2 面向桌面开发,Ubuntu Server 面向无头服务器)