Linux下安装virtual box
1 下载virtual box 地址:
https://www.virtualbox.org/wiki/Linux_Downloads
需要确定linux 系统OS的发行版本
2 安装
加权限之后rpm -ivh 加包名
3安装过程中出现过错误:
[root@localhost ~]# /etc/init.d/vboxdrv setup
Stopping VirtualBox kernel module [ OK ]
Recompiling VirtualBox kernel module [FAILED]
[root@localhost ~]# cat /var/log/vbox-install.log
. Specify KERN_DIR=<directory> and run Make again. Stop.
Makefile:183: *** Error: unable to find the sources of your current Linux kernel
. Specify KERN_DIR=<directory> and run Make again. Stop.
Makefile:183: *** Error: unable to find the sources of your current Linux kernel
. Specify KERN_DIR=<directory> and run Make again. Stop.
原因:缺少kernel的source文件
使用yum 安装。
yum install kernel
另外还需要安装gcc
安装完成之后需要reboot
再重新运行/etc/init.d/vboxdrv setup
>> /etc/init.d/vboxdrv setup
Stopping VirtualBox kernel modules [ OK ]
Recompiling VirtualBox kernel modules [ OK ]
Starting VirtualBox kernel modules [ OK ]
1 下载virtual box 地址:
https://www.virtualbox.org/wiki/Linux_Downloads
需要确定linux 系统OS的发行版本
2 安装
加权限之后rpm -ivh 加包名
3安装过程中出现过错误:
[root@localhost ~]# /etc/init.d/vboxdrv setup
Stopping VirtualBox kernel module [ OK ]
Recompiling VirtualBox kernel module [FAILED]
[root@localhost ~]# cat /var/log/vbox-install.log
. Specify KERN_DIR=<directory> and run Make again. Stop.
Makefile:183: *** Error: unable to find the sources of your current Linux kernel
. Specify KERN_DIR=<directory> and run Make again. Stop.
Makefile:183: *** Error: unable to find the sources of your current Linux kernel
. Specify KERN_DIR=<directory> and run Make again. Stop.
原因:缺少kernel的source文件
使用yum 安装。
yum install kernel
另外还需要安装gcc
安装完成之后需要reboot
再重新运行/etc/init.d/vboxdrv setup
>> /etc/init.d/vboxdrv setup
Stopping VirtualBox kernel modules [ OK ]
Recompiling VirtualBox kernel modules [ OK ]
Starting VirtualBox kernel modules [ OK ]
附加几个命令:
启动vnc server:vncserver
在服务器端修改vmcserver的密码: vncpasswd
yum 安装命令:
yum install
yum clean all 清除缓存