In this post we will discuss how to get VirtualBox 5 guest additions installed on CentOS 7.
Installing VirtualBox Additions
First make sure updates have been applied and if there was a kernel update that the system was rebooted. Do this the typical way by running the command.
$ sudo yum -y update
Now that we have the latest updates and have rebooted we need to install epel to allow us to get some required packages needed for Guest Additions.
Next we are ready to install dkms and kernel-devel that are required for guest additions to compile.
Install the guest additions. Click Devices > Install Guest Additions CD Image. If you have installed the GUI with CentOS 7 you will receive a popup asking if you want to install VBOXADDITIONS. Click Run and enter in your credentials and the installation will proceed. If you are not using the GUI open a terminal and type the following.
Note: The mount path will have your login id and the VBOXADDITIONS version maybe different. To get the correct path run the mount command.
$ cd /run/media/<yourid>/VBOXADDITIONS_5_0_2_102096
Now we can start the installer. At the terminal type:
$ sudo ./VBoxLinuxAdditions.run
Be patient and wait for the process to run.
Reboot and you will now have all the features that the Guest Additions will give.
And there we have it, you have the VirtualBox guest additions installed and working on your CentOS 7 system.