我正在尝试在我的 WLS 上启动 Vagrant 盒。我安装了 Virtual Box,然后尝试执行 vagrant up,结果引发了以下错误。
VirtualBox is complaining that the kernel module is not loaded. Please run VBoxManage --version or open the VirtualBox GUI to see the error message which should contain instructions on how to fix this error.
然后我给了VBoxManage --version
它引发了以下错误
libkmod: ERROR ../libkmod/libkmod-module.c:1657 kmod_module_new_from_loaded: could not open /proc/modules: No such file or directory Error: could not get list of modules: No such file or directory WARNING: The vboxdrv kernel module is not loaded. Either there is no module available for the current kernel (4.4.0-17134-Microsoft) or it failed to load. Please recompile the kernel module and install it by sudo /sbin/vboxconfig You will not be able to start VMs until this problem is fixed. 5.2.28r130011
然后我也尝试从 root 位置执行 /sbin/vboxconfig。
System has not been booted with systemd as init system (PID 1). Can't operate. vboxdrv.sh: Stopping VirtualBox services. libkmod: ERROR ../libkmod/libkmod-module.c:1657 kmod_module_new_from_loaded: could not open /proc/modules: No such file or directory Error: could not get list of modules: No such file or directory
答案1
我正在尝试在我的 WLS 上启动一个 Vagrant 盒子。
的当前版本Windows Linux Subsystem
不支持您想要的功能。直到 WSL 运行完整的 Linux 内核后,您想要的功能才可实现。
WSL 2 使用最新、最先进的虚拟化技术在轻量级实用程序虚拟机 (VM) 中运行其 Linux 内核。
WSL 2 的初始版本将于 2019 年 6 月底通过 Windows Insider 计划推出。
来源:宣布 WSL 2