Oracle VirtualBox 5.2 is the latest major release after launched by Oracle team. This article helps you to install VirtualBox on Debian 9 and Debian 8 systems.
Step 1 – Prerequsities
You must have logged in to your server using root or sudo privileged user. After login to your system update current packages of the system to the latest version.
sudo apt-get update sudo apt-get upgrade
Step 2 – Setup Apt Repository
Let’s import the Oracle public key to your system signed the Debian packages using the following commands.
wget -q https://www.virtualbox.org/download/oracle_vbox_2016.asc -O- | sudo apt-key add - wget -q https://www.virtualbox.org/download/oracle_vbox.asc -O- | sudo apt-key add -
Now execute the following command to configure Apt repository on your Debian system. This command will add an entry to /etc/apt/sources.list at end of the file.
sudo add-apt-repository "deb http://download.virtualbox.org/virtualbox/debian `lsb_release -cs` contrib"
Step 3 – Install Oracle VirtualBox
After completing the above steps, let’s install VirtualBox using the following commands. If you have already installed an older version of VirtualBox, Below command will update it automatically.
sudo apt-get update sudo apt-get install virtualbox-5.2
Step 4 – Launch VirtualBox
We can use dashboard shortcuts to start VirtualBox or simply run following command from a terminal.