Header Ads

How to Install Oracle VirtualBox 5.1 on CentOS/RHEL 7

The Oracle VirtualBox is basically a virtualization application that runs on all platforms. What makes it more reliable and commonly used is beause it works well on all computers including the ones with low specs. It can run on Windows, Mac, Linux or Solaris operating systems

The latest VirtualBox version (as of this writing) is 5.1.2 which was released on on July 21st, 2016. This new VirtualBox version has come with an improved stability and fixes a few regressions.
If you have been reading our past tutorials, we have covered basic installation in all main operating systems, including fixing of some issues that arose when running virtualbox.

This tutorial will help you install Oracle VirtualBox 5.1 on CentOS, Redhat and Fedora systems using Yum.

Add Yum Repositories

The first thing you wanna do is add VirtualBox yum repository in your system. To do so, Download repository file from the official website and store it in /etc/yum.repos.d/virtualbox.repo .First go to /etc/yum.repos.d/ directory and use one of below commands as per your operating system.

Installing VirtualBox requires kernel source code to install required modules, So you first need to configure environment variables KERN_DIR this is where VirtualBox will get kernel source code. In my case latest kernel source can be found at 2.6.32-504.3.3.el6.x86_64 directory under /usr/src/kernels/ . Make sure you are using correct source path.