How to install VirtualBox on CentOS 8

s2 0

VirtualBox is free, cross-platform, open source software for virtualization. It enables users to run multiple virtual machines of different flavors at the same time on a single PC. It is mainly used at the desktop level and supports various guest operating systems including Linux and Windows. For example, Virtualbox comes in handy when you are trying to explore features of different operating system distributions or develop software.

This article will show you how to install VirtualBox on CentOS 8.

Installation steps of VirtualBox on CentOS 8

The following steps are required to install VirtualBox on CentOS 8.

  1. Open the terminal application on your system.
  2. Log into your system as the root user. Or you enter the command ‘su’ in the terminal window. You are now logged in as an admin user.

Activate EPEL repository

Activate the EPEL repository of Oracle’s VirtualBox. To activate the EPEL repository, run the following command on the terminal:

$ sudo dnf config-manager --add-repo=https://download.virtualbox.org/virtualbox/rpm/el/virtualbox.repo

Install VirtualBox 6.0

Now install VirtualBox on your system using the yum command. This tutorial for installing VirtualBox version 6.0. To install this version of VirtualBox on your CentOS 8.0 you need to run the following command on the terminal:

$ sudo yum install VirtualBox-6.0

During the installation process, a prompt will interrupt the Virtualbox installation, asking you whether you want to download the required packages for Virtualbox or not. After a while, another security question will appear on the terminal confirming that you want to import the GPG key or not. You will press ‘y’ to continue.

Download packages

After you have taken the necessary actions, Virtualbox has now been installed on your CentOS 8.0.

Download the VirtualBox expansion pack

It’s time to install an expansion pack for Virtualbox. It has many useful features that include virtual USB 2.0, 3.0 devices, disk image encryption, and support for virtual RDP.

You can download the extension pack from the Virtualbox download page using the ‘wget’ command. Run the below mentioned command on the terminal to download the Virtualbox expansion package on CentOS 8.0.

$ wget https://download.virtualbox.org/virtualbox/6.0.14/Oracle_VM_VirtualBox_Extension_Pack-6.0.14.vbox-extpack

Download the VirtualBox expansion pack
You can see in the above output that Oracle’s Virtualbox expansion package has been successfully saved in your CentOS 8.0 system.advertising

  1. Install expansion pack

Once the file download is complete, now install the downloaded file on your system. You run the following command to install the Oracle Virtualbox Extension Pack:

$ sudo VBoxManage extpack install Oracle_VM_VirtualBox_Extension_Pack-6.0.14.vbox-extpack

Install the expansion pack using the VBoxManage command

A license agreement is displayed on the terminal screen during installation. You will press ‘y’ then ‘Enter’ to accept the terms for Virtualbox.

The following output will be displayed on the screen after the installation of the Virtualbox Extension Pack is successfully completed.

Installation successful

Start VirtualBox

The Virtualbox Extension Pack from Oracle has been installed on your CentOS 8.0. Now start or start the Virtualbox on your system. You enter the following command on the terminal to start Virtualbox in a command line environment.

$ virtualbox

When you start Virtualbox for the first time on your system, the following window should appear on your CentOS 8.0.

Start VirtualBox

An alternative method is also available to start Virtualbox on the system. Click on “Activities” in the left corner of the desktop and select Show applications where you can see the Virtualbox icon on the desktop.

VirtualBox on the desktop

Now you can use Virtualbox to create and run various work machines such as Windows and Linux on your system.

diploma

In this article you learned how to install Virtualbox on your CentOS 8 system. You also learned how to download and install necessary packages for Virtualbox. I hope this tutorial will be helpful to you in the future. Now you can install and use Virtualbox on any Linux distribution from CentOS. If you have any questions, please mention them in the comment field.

How to install VirtualBox on CentOS 8