ubuntu - 由于未安装内核驱动程序,无法在虚拟机上启动 guest 操作系统

标签 ubuntu virtualbox

我在 Ubuntu 主机和 Windows 7 上使用 Virtual Box 作为 guest 操作系统。我之前可以多次运行 Windows,但最近在我的 Ubuntu Box 上安装更新后,它显示错误。下面是错误的截图——
enter image description here

以下是错误的详细信息-

The virtual machine 'Windows' has terminated unexpectedly during startup with exit code 1 (0x1).


Result Code: 
NS_ERROR_FAILURE (0x80004005)
Component: 
MachineWrap
Interface: 
IMachine {f30138d4-e5ea-4b3a-8858-a059de4c93fd}

根据建议,我尝试运行 sudo /sbin/rcvboxdrv setup在终端上,但失败并显示以下消息-
ravi@Dell:~$ sudo /sbin/rcvboxdrv setup
Stopping VirtualBox kernel modules ...done.
Removing old VirtualBox pci kernel module ...done.
Removing old VirtualBox netadp kernel module ...done.
Removing old VirtualBox netflt kernel module ...done.
Removing old VirtualBox kernel module ...done.
Recompiling VirtualBox kernel modules ...done.
Starting VirtualBox kernel modules ...failed!
  (modprobe vboxdrv failed. Please use 'dmesg' to find out why)
dmesg命令显示以下信息-
ravi@Dell:~$ dmesg|tail
[11128.973745] i915 0000:00:02.0: BAR 6: [??? 0x00000000 flags 0x2] has bogus alignment
[11130.401285] dell_laptop: Keyboard brightness level control not supported
[11195.330664] audit_printk_skb: 153 callbacks suppressed
[11195.330671] audit: type=1400 audit(1468644989.132:62): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="/usr/lib/cups/backend/cups-pdf" pid=6051 comm="apparmor_parser"
[11195.330689] audit: type=1400 audit(1468644989.132:63): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="/usr/sbin/cupsd" pid=6051 comm="apparmor_parser"
[11195.331654] audit: type=1400 audit(1468644989.132:64): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="/usr/sbin/cupsd" pid=6051 comm="apparmor_parser"
[11854.988254] systemd-hostnamed[6528]: Warning: nss-myhostname is not installed. Changing the local hostname might make it unresolveable. Please install nss-myhostname!
[16286.725959] capability: warning: `VirtualBox' uses 32-bit capabilities (legacy support in use)
[16893.539293] systemd-hostnamed[9073]: Warning: nss-myhostname is not installed. Changing the local hostname might make it unresolveable. Please install nss-myhostname!
[17477.423820] systemd-hostnamed[11935]: Warning: nss-myhostname is not installed. Changing the local hostname might make it unresolveable. Please install nss-myhostname!

虚拟盒子日志/var/log/vbox-install.log正在显示 Kernel configuration is invalid .请在日志文件中查看以下错误 -
test -e include/generated/autoconf.h -a -e include/config/auto.conf || (        \
    echo >&2;                           \
    echo >&2 "  ERROR: Kernel configuration is invalid.";       \
    echo >&2 "         include/generated/autoconf.h or include/config/auto.conf are missing.";\
    echo >&2 "         Run 'make oldconfig && make prepare' on kernel src to fix it.";  \
    echo >&2 ;                          \
    /bin/false)
mkdir -p /tmp/vbox.0/.tmp_versions ; rm -f /tmp/vbox.0/.tmp_versions/*

我试过sudo make oldconfig && make prepare但它也失败了。以下是错误消息-
ravi@Dell:/usr/src$ uname -a
Linux Dell 4.2.0-42-generic #49~14.04.1-Ubuntu SMP Wed Jun 29 20:22:11 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

ravi@Dell:/usr/src/linux-headers-4.2.0-42-generic$ sudo make oldconfig && make prepare
[sudo] password for ravi: 
  HOSTCC  scripts/basic/fixdep
  HOSTCC  scripts/basic/bin2c
  HOSTCC  scripts/kconfig/conf.o
  HOSTCC  scripts/kconfig/zconf.tab.o
  HOSTLD  scripts/kconfig/conf
scripts/kconfig/conf  --oldconfig Kconfig
#
# configuration written to .config
#
arch/x86/Makefile:138: CONFIG_X86_X32 enabled but no binutils support
Makefile:662: Cannot use CONFIG_CC_STACKPROTECTOR_REGULAR: -fstack-protector not supported by compiler
scripts/kconfig/conf  --silentoldconfig Kconfig

*** Error during update of the configuration.

make[2]: *** [silentoldconfig] Error 1
make[1]: *** [silentoldconfig] Error 2
make[1]: *** No rule to make target `arch/x86/entry/syscalls/syscall_32.tbl', needed by `arch/x86/entry/syscalls/../../include/generated/asm/syscalls_32.h'.  Stop.
make: *** [archheaders] Error 2

以下是其他信息-
VirtualBox Graphical User Interface
Version 5.0.24 r108355
Copyright © 2016 Oracle Corporation and/or its affiliates. All rights reserved.

最佳答案

如果您最近安装了新的内核版本,请尝试使用较早的版本。内核 vmlinuz-4.2.0-42-generic 对我不起作用,但 vmlinuz-4.2.0-41-generic 有效。显然, vmlinuz-4.2.0-42-generic 没有 vboxdrv 版本。我正在使用 VirtualBox 5.1。

关于ubuntu - 由于未安装内核驱动程序,无法在虚拟机上启动 guest 操作系统,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38408648/

相关文章:

ubuntu - OpenSSL SSL_ERROR_SYSCALL 连接到 raw.githubusercontent.com :443

ubuntu - 如何获取 nginx 使用的当前 worker 连接?

centos - 试图在 VirtualBox 的上下文中理解 ISO 镜像

linux - 无法访问 Virtual Box 中的共享文件夹

android - 从源代码构建 Android - 区分大小写的文件系统

node.js - Ubuntu:Node 将不会更新到最新版本

python - 为什么这个 python 脚本只能在 Ubuntu 12.04 上的 IDLE 下工作?

ubuntu - 在 Ubuntu 上解锁 Jenkins

centos - Vagrant 启动时设置超时

installation - 如何在 VirtualBox 中分发我稍微定制的 Linux?