分类: LINUX
2011-08-16 11:18:11
首先从virtualbox官网下载相应的版本,下载后安装。
安装后启动virtualbox 时报错
Kernel
driver not installed (rc=-1908)
The VirtualBox Linux kernel driver (vboxdrv) is either not loaded or there is a
permission problem with /dev/vboxdrv. Please reinstall the kernel module by
executing
'/etc/init.d/vboxdrv setup'
as root. Users of Ubuntu, Fedora or Mandriva should install the DKMS package
first. This package keeps track of Linux kernel changes and recompiles the
vboxdrv kernel module if necessary.
解决方法
sudo aptitude update
sudo aptitude install dkms
sudo /etc/init.d/vboxdrv setup 执行完setup后报错。
1、 查看系统报错日志
Uninstalling modules from DKMS
removing old DKMS module vboxhost version 4.1.0
------------------------------
Deleting module version: 4.1.0
completely from the DKMS tree.
------------------------------
Done.
Attempting to install using DKMS
Creating symlink /var/lib/dkms/vboxhost/4.1.0/source ->
/usr/src/vboxhost-4.1.0
DKMS: add Completed.
You can use the --kernelsourcedir option to tell DKMS where it's located, or you could install the linux-headers-2.6.38 package.
Failed to install using DKMS, attempting to install without
Makefile:175: Warning: using /usr/src/linux
as the source directory of your Linux kernel. If this is not correct, specify
KERN_DIR=
// 经查看/usr/src/vboxhost-4.1.0/vboxdrv/下的
Makefile:175中/usr/src/linux/ 提示的目录不存在,导致驱动在编译时候报错。
2、建立软连接
root@bt:/usr/src# ln -s linux-headers-2.6.38/ linux 指向Make efile 中定义的路径
3、重新安装
./etc/init.d/vboxdrv setup 编译
4、开始-system-启动