Enabling Hardware Virtualization:
Before you read any further, please enable VT-x/VT-d/AMD-v from the BIOS of your computer. VT-x/VT-d for Intel processors and AMD-v is for AMD processors. You should be able to find one of these in the BIOS depending on the processor you’re using. Without hardware virtualization enabled, the performance of your virtual machines will be really bad. It is obviously not what you want.
Downloading VirtualBox 6.0:
VirtualBox 6.0 is not available in the official package repository of Debian 8, Debian 9 or Debian 10. But, you can easily download and install it from the official website of VirtualBox.
First, visit the official website of VirtualBox at https://www.virtualbox.org/wiki/Linux_Downloads
Now, click on either Debian 8, Debian 9, or Debian 10 link depending on the version of Debian you’re using.
Your browser should prompt you to download the DEB package file. Select Save File and click on OK.
Your download should start. It may take a while to complete.
Installing Required Build Tools for Compiling VirtualBox 6.0 Kernel Modules:
In order to successfully compile the VirtualBox 6.0 kernel module, you have to have the required build tools installed on your Debian machine. Otherwise, VirtualBox 6.0 may not work correctly.
First, update the APT package repository cache with the following command:
Now, install all the required build tools with the following command:
Now, press y and then press <Enter> to continue.
All the required packages should be downloaded and installed.
All the required build tools are installed at this point.
Installing VirtualBox 6.0:
Now that VirtualBox 6.0 DEB package is downloaded and the system is ready to compile the VirtualBox kernel modules, we can install VirtualBox 6.0 on our Debian machine very easily.
First, navigate to the directory where you downloaded the VirtualBox 6.0 DEB file with the following command:
As you can see, the VirtualBox DEB package file is here.
Now, install VirtualBox 6.0 with the following command:
You may see the following errors.
To fix that and install VirtualBox 6.0, just run the following command:
Now, press y and then press <Enter>.
VirtualBox 6.0 should be installed.
Starting VirtualBox 6.0:
Now that VirtualBox 6.0 is installed, you can run it from the Application Menu of your desired desktop environment.
VirtualBox 6.0 has started. This is the dashboard of VirtualBox 6.0. From here you can create and manage virtual machines. You can also configure VirtualBox 6.0.
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.
To download VirtualBox Extension Pack, go to the official website of VirtualBox at https://www.virtualbox.org/wiki/Downloads and navigate to the VirtualBox 6.0.0 Oracle VM VirtualBox Extension Pack section. Now, click on All supported platforms as marked in the screenshot below.
Your browser should prompt you to download the file. Just select Save File and click on OK.
Your browser should start downloading the file. It may take a while to complete.
Installing VirtualBox Extension Pack on VirtualBox 6.0:
Now, to install VirtualBox Extension Pack on VirtualBox 6.0, start VirtualBox 6.0 and go to File > Preferences…
Now, from the Extensions tab, click on Add icon as marked in the screenshot below.
A file picker should be opened. Now, select the VirtualBox Extension Pack file that you just downloaded and click on Open.
Now, click on Install.
Now, you have to accept the VirtualBox License Agreement. To do that, just scroll down to the end and click on I Agree.
Now, type in your root password and click on OK.
VirtualBox Extension Pack should be installed. Now, click on OK.
Click on OK.
Now, you’re ready to use VirtualBox 6.0.
So, that’s how you install VirtualBox 6.0 on Debian. Thanks for reading this article.