[root@localhost sysadmin]# /etc/init.d/vboxdrv setup
Stopping VirtualBox kernel modules [ OK ]
Uninstalling old VirtualBox DKMS kernel modules [ OK ]
Trying to register the VirtualBox kernel modules using DKMSError! echo
Your kernel headers for kernel 2.6.32-431.20.3.el6.i686 cannot be found at
/lib/modules/2.6.32-431.20.3.el6.i686/build or /lib/modules/2.6.32-431.20.3.el6.i686/source.
[FAILED]
(Failed, trying without DKMS)
Recompiling VirtualBox kernel modules [FAILED]
(Look at /var/log/vbox-install.log to find out what went wrong)
[root@localhost sysadmin]#
我使用的是 CentOS 32 位版本。
答案1
kernel-headers
通过执行以下操作安装:
yum install kernel-headers
另请确保您已更新并实际运行上述内核(如果您更新了内核,请重新启动)。