Skip to content

解决 WslRegisterDistribution 失败错误 0x800701bc

问题描述

在 Windows 系统中安装 Ubuntu 或其他 Linux 发行版时,可能会遇到 WslRegisterDistribution failed with error: 0x800701bc 错误。这个错误通常与 Windows Subsystem for Linux (WSL) 的配置和内核更新有关。

解决方案

方法一:更新 WSL 内核(推荐)

这是最常见且有效的解决方案:

powershell
# 更新 WSL 内核
wsl --update

# 安装 Ubuntu(会自动选择最新版本)
wsl --install -d ubuntu

# 或者指定 Ubuntu 22.04 LTS
wsl --install -d Ubuntu-22.04
cmd
# 设置 WSL 版本为 2
wsl --set-default-version 2

方法二:启用必要的 Windows 功能

确保以下 Windows 功能已启用:

  1. 打开"启用或关闭 Windows 功能"
  2. 勾选以下两个选项:
    • Virtual Machine Platform(虚拟机平台)
    • Windows Subsystem for Linux(适用于 Linux 的 Windows 子系统)
  3. 重启计算机

注意

如果 Virtual Machine Platform 未启用,即使已经安装了 WSL,也可能出现 0x800701bc0x80370114 错误。

方法三:手动安装内核更新

如果自动更新失败,可以尝试手动安装:

  1. Microsoft 官方文档 下载最新版的 WSL 内核更新包
  2. 运行 wsl_update_x64.msi 安装程序
  3. 如果安装失败,可以尝试手动提取内核文件:
cmd
msiexec /a "wsl_update_x64.msi" /qb TARGETDIR="C:\temp"

然后将 C:\temp 中的内核文件复制到 C:\Windows\System32\lxss\tools 目录。

验证安装

安装完成后,可以使用以下命令验证和管理 WSL:

powershell
wsl --list
powershell
wsl --list --online
powershell
wsl --set-default Ubuntu-22.04
powershell
wsl

常见问题排查

启用 CPU 虚拟化

确保在 BIOS/UEFI 设置中启用了 CPU 虚拟化支持(Intel VT-x 或 AMD-V)。

兼容性检查

系统要求

  • Windows 10 版本 1903 或更高版本,或 Windows 11
  • 64 位操作系统
  • 已启用硬件虚拟化支持

总结

WslRegisterDistribution failed with error: 0x800701bc 错误通常是由于 WSL 内核版本过旧或必要的 Windows 功能未启用所致。通过更新 WSL 内核、启用 Virtual Machine Platform 功能,或手动安装内核更新,可以解决这个问题。

按照上述步骤操作后,应该能够成功安装和运行 Ubuntu 或其他 Linux 发行版。如果问题仍然存在,建议查看 Microsoft 官方 WSL 文档 或相关的 GitHub 问题讨论。