VirtualBox

Installing Virtual Box on Debian

VirtualBox is a free and open source virtualization solution from Oracle. VirtualBox is cross-platform. It runs on Windows, Linux, and macOS.

In this article, I am going to show you how to install VirtualBox on Debian 10. So, let’s get started.

Prerequisites:

Before you get started, you should enable hardware virtualization (AMD-v/VT-d/VT-x) extension from the BIOS of your motherboard. Otherwise, you won’t get very good performance in virtual machines.

Adding Oracle VirtualBox Package Repository:

VirtualBox 6.0 is the latest version of VirtualBox at the time of this writing. It is not available in the official package repository of Debian 10 Buster. But, you can easily add the Oracle VirtualBox package repository on Debian 10 and install VirtualBox 6.0 from there.

To add the Oracle VirtualBox package repository, run the following command:

$ echo 'deb https://download.virtualbox.org/virtualbox/debian buster contrib' |
 sudo tee /etc/apt/sources.list.d/virtualbox.list

The VirtualBox package repository should be added.

Adding GPG Key:

Now, download the GPG key of the Oracle VirtualBox package repository with the following command:

$ wget -O /tmp/oracle_vbox.asc https://www.virtualbox.org/download/oracle_vbox_2016.asc

The GPG key should be downloaded.

Now, add the GPG key to the APT package manager with the following command:

$ sudo apt-key add /tmp/oracle_vbox.asc

The GPG key should be added.

Updating APT Cache:

Now, update the APT package repository cache with the following command:

$ sudo apt update

The APT package repository cache should be updated.

Installing VirtualBox:

Now, you can install VirtualBox 6.0 with the following command:

$ sudo apt install virtualbox-6.0

Now, press Y and then press <Enter> to confirm the installation.

The APT package manager should download and install all the required packages.

VirtualBox 6.0 should be installed at this point.

Once VirtualBox 6.0 is installed, you should be able to find it in the Application Menu of Debian 10. Click on the VirtualBox logo.

VirtualBox should start.

Downloading VirtualBox Extension Pack:

VirtualBox Extension Pack adds features such as USB 2.0 and USB 3.0 support, RDP, disk encryption etc on top of VirtualBox. I highly recommend you download and install it for a smooth VirtualBox 6.0 experience.

First, you have to find out the full version number of VirtualBox.

You can find the full version number from the command line with the following command:

$ apt-cache show virtualbox-6.0 | grep Version

As you can see, the full version number of the VirtualBox installed on my computer is 6.0.10. Remember it.

You can also find the full version number from the VirtualBox Manager. Just open VirtualBox and go to Help > About VirtualBox…

As you can see, the full version number is 6.0.10

Now, visit the following webpage https://download.virtualbox.org/virtualbox/6.0.10

Once the page loads, click on the “Oracle_VM_VirtualBox_Extension_Pack-6.0.10.vbox-extpack” file as marked in the screenshot below.

NOTE: Replace 6.0.10 with the version you’ve installed on your Debian 10 machine.

Your browser should prompt you to save the file. Select Save File and click on OK.

The download should start. It may take a few minutes to complete.

Installing VirtualBox Extension Pack:

Once the download is completed, open VirtualBox and go to File > Preferences…

Now, go to the Extensions tab and click on the add icon as marked in the screenshot below.

Now, select the vbox-extpack file you just downloaded and click on Open.

Now, click on Install.

Read the VirtualBox License agreement if you wish and click on I Agree.

Now, type in the password of your Debian 10 login user and click on Authenticate.

VirtualBox Extension Pack should be installed. Now, click on OK.

Click on OK to close the Preferences window.

You’ve successfully installed VirtualBox 6.0 (the latest version at the time of this writing) on Debian 10 buster. Enjoy!

Thanks for reading this article.

About the author

Shahriar Shovon

Freelancer & Linux System Administrator. Also loves Web API development with Node.js and JavaScript. I was born in Bangladesh. I am currently studying Electronics and Communication Engineering at Khulna University of Engineering & Technology (KUET), one of the demanding public engineering universities of Bangladesh.