fedora25 (centos 7)安装virtualbox详细步骤(保证一次成功)
来源:互联网 发布:js修改img的src 编辑:程序博客网 时间:2024/06/06 13:19
VirtualBox supports a large number of guest operating systems:
- Windows 3.x
- Windows NT 4.0
- Windows 2000
- Windows XP
- Windows Server 2003
- Windows Server 2008
- Windows Vista
- Windows 7
- Windows 8
- Windows 8.1
- Windows 10
- DOS
- Linux (2.4, 2.6, 3.0, 3.2, 3.4, 3.10, 3.16, 3.18, 4.1, 4.4, 4.7, 4.8, 4.9, 4.10, 4.11)
- Solaris
- OpenSolaris
- OpenBSD
This guide shows howto install VirtualBox 5.1 (currently 5.1.26) on Fedora 26/25/24/23/22, CentOS 7.3/6.9, Red Hat (RHEL) 7.3/6.9/5.11. This guide uses Virtual Box own yum repositories.
Note: Fedora 21/20/19/18 users can install VirtualBox 5.0, Fedora 17 users can install VirtualBox 4.3 and Fedora 16 users can install VirtualBox 4.2.
1. Change to root User
su -## OR ##sudo -i
2. Install Fedora or RHEL Repo Files
cd /etc/yum.repos.d/## Fedora 26/25/24/23/22/21/20/19/18/17/16 userswget http://download.virtualbox.org/virtualbox/rpm/fedora/virtualbox.repo## CentOS 7.3/6.9 and Red Hat (RHEL) 7.3/6.9 userswget http://download.virtualbox.org/virtualbox/rpm/rhel/virtualbox.repo
3. Update latest packages and check your kernel version
Update packages
## Fedora 26/25/24/23/22 ##dnf update## Fedora 21/20/19/18/17/16 and CentOS/RHEL 7/6/5 ##yum update
Check that that you are running latest installed kernel version
Output of following commands version numbers should match:
rpm -qa kernel |sort -V |tail -n 1uname -r
Note: If you got kernel update or run older kernel than newest installed then reboot:
reboot
4. Install following dependency packages
CentOS 7/6/5 and Red Hat (RHEL) 7/6/5 needs EPEL repository, install it with following command:
## CentOS 7 and RHEL 7 ##rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm## CentOS 6 and RHEL 6 ##rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm## CentOS 5 and RHEL 5 ##rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-5.noarch.rpm
## Fedora 26/25/24/23/22 ##dnf install binutils gcc make patch libgomp glibc-headers glibc-devel kernel-headers kernel-devel dkms## Fedora 21/20/19/18/17/16 and CentOS/RHEL 7/6/5 ##yum install binutils gcc make patch libgomp glibc-headers glibc-devel kernel-headers kernel-devel dkms## PAE kernel users install #### Fedora 24/23/22 ##dnf install binutils gcc make patch libgomp glibc-headers glibc-devel kernel-headers kernel-PAE-devel dkms## Fedora 21/20/19/18/17/16 and CentOS/RHEL 7/6/5 ##yum install binutils gcc make patch libgomp glibc-headers glibc-devel kernel-headers kernel-PAE-devel dkms
## Fedora 26/25/24/23/22 ##dnf install VirtualBox-5.1## Fedora 21/20/19/18/17/16/15/14 and CentOS/RHEL 7/6/5 ##yum install VirtualBox-5.1
Note:
This command create automatically vboxusers group and VirtualBox user must be member of that group.
This command also build needed kernel modules.
Package is VirtualBox-5.1 not VirtualBox.
Rebuild kernel modules with following command:
## Fedora 26/25/24/23/22/21/20/19 and CentOS/RHEL 7 ##/usr/lib/virtualbox/vboxdrv.sh setup## Fedora 18/17/16 and CentOS/RHEL 6/5 ##/etc/init.d/vboxdrv setup## OR ##service vboxdrv setup
6. Add VirtualBox User(s) to vboxusers Group
Replace user_name with your own user name or some another real user name.
usermod -a -G vboxusers user_name
7. Start VirtualBox
Use launcher from menu or simply run:
VirtualBox
Troubleshooting
If you have problems with KERN_DIR parameter or your kernel directory is not automatically detected then set KERN_DIR environment variable manually, using following method:
## Current running kernel on Fedora ##KERN_DIR=/usr/src/kernels/`uname -r` ## Current running kernel on CentOS and Red Hat (RHEL) ##KERN_DIR=/usr/src/kernels/`uname -r`-`uname -m` ## Fedora example ##KERN_DIR=/usr/src/kernels/2.6.33.5-124.fc13.i686 ## CentOS and Red Hat (RHEL) example ##KERN_DIR=/usr/src/kernels/2.6.18-194.11.1.el5-x86_64 ## Export KERN_DIR ##export KERN_D
- fedora25 (centos 7)安装virtualbox详细步骤(保证一次成功)
- fedora25安装VirtualBox的注意事项
- CentOS 7 安装 JDK8 详细步骤
- CentOS 7 安装 redis3.0.7 详细步骤
- CentOS 7 安装 mariaDB 详细步骤
- centOS安装mysql5.7详细步骤
- Docker安装详细步骤(CentOS环境)
- VirtualBox下安装CentOS详细教程(截图版)
- CentOS 下的VirtualBox 安装步骤
- CentOS 7 安装VirtualBox
- CentOS 7 安装VirtualBox
- CentOS 7 安装VirtualBox
- CentOS 7 安装VirtualBox
- CentOS安装python3详细步骤
- VirtualBox 安装 CentOs 6.3图文详细教程
- VirtualBox 安装 CentOs 6.3图文详细教程
- myeclipse9.0 安装svn (详细步骤,肯定成功)
- VirtualBox安装linux(CentOS 7)虚拟机
- [iOS]UITextFiled限制输入整数与小数位数
- Callable接口实现多线程
- 第五十一篇:JAVA简易WEB服务器(一)
- pandas concat表连接
- [PHP学习]TP5开篇学习-TP5中的build配置目录及自动生成使用问题
- fedora25 (centos 7)安装virtualbox详细步骤(保证一次成功)
- Java三目运算符数值类型的自动转换
- 【技术】NGUI官网示例1-UIAnchor
- jquery获取当前系统时间--已解决
- Spring使用Cache
- mavenCenter和JCenter
- jqgrid实现单个字段的背景色根据内容变色
- Quartz学习
- 从HTTP到HTTPS再到HSTS