1. Download the VirtualBox repo file:
Login Https://www.virtualbox.org/wiki/Linux_Downloads Right-click on the repo link at the bottom of the page, or download it wget
[Email protected] files]# wget Http://download.virtualbox.org/virtualbox/rpm/el/virtualbox.repo
And put it under the path /etc/yum.repos.d .
2. Check the available software versions:
Enter Yum List virtualbox*
[[email protected] files]# Yum list virtualbox*
loaded plug-in: Fastestmirror, LangPacks
Loading Mirror speeds from cached hostfile
* elrepo:dfw.mirror.rackspace.com
Installed packages
virtualbox-5.1.x86_64 5.1.26_ 117224_el7-1 @virtualbox "I've installed the version 5.1 earlier"
Installable Packages
Virtualbox-4.3.x86 _64 4.3.40_110317_el7-1 VirtualBox
Virtualbox-5.0.x86 _64 5.0.40_115130_el7-1 VirtualBox
3. Installation:
Yum Install VirtualBox-5.1
Complete the installation
==============================================
Tips: Start a virtual machine times wrong handling
Open VirtualBox from the desktop and create a new virtual machine after the installation is complete all right, wait until the virtual machine starts to error /sbin/vboxconfig
This time to enter the terminal on the VirtualBox, the hint is not available kernel or kernel not loaded information, and prompted to run/sbin/vboxconfig to see the details, after the run found two hints a missing gcc, The other is kernel's problem.
Decisive release of the dog, it is necessary to kernel-devel this component, found the problem that installation on the line.
"For Elrepo sources, see the previous blog post on the elrepo source Configuration in CentOS 7 http://www.cnblogs.com/zhaowp88/p/7382931.html"
[[email protected] files]# Yum install gcc
[email protected] files]# Yum--enablerepo=elrepo-kernel install Kernel-devel
After the completion of the run /sbin/vboxconfig no error prompts, run VirtualBox again to start the virtual machine, smooth start, done!
2017-08-17 17:54:17
CentOS 7 Installation Oracle VirtualBox