How to Install Latest VirtualBox 6.0.10 on Debian 10 Buster
This tutorial will be showing you how to install Oracle VirtualBox on Debian 10 Buster. VirtualBox is a free and open-source (GPLv2) virtualization software that can be used in enterprise as well as at home. It can run on Linux, MacOS, Windows and Solaris. The latest VirtualBox 6.0.10 was released on July 16, 2019 by Oracle. Below are some of the highlights in the VirtualBox 6.x series:
- VirtualBox 6.0 bring a major revamp to the user interface, providing users with a much simpler graphical interface.
- Implemented support for exporting a virtual machine to Oracle Cloud Infrastructure
- Support for nested hardware-virtualization on AMD CPUs
- Greatly improved HiDPI and scaling support, including better detection and per-machine configuration
- Support for surround speaker setups
- Support UEFI secure boot driver signing on Ubuntu and Debian hosts
- Ability to remember the guest screen size after a guest reboot
- Support Linux 5.0 and 5.1 kernels (Ubuntu 19.04 ships with Linux 5.0 kernel.)
- Improved performance and reliability of the shared folder feature
- Basic support for VMSVGA graphics device in virtual machines using EFI
- USB: modified Linux backends to reset USB devices (previously, most guest attempts to reset USB devices were ignored)
VirtualBox 6.0 dropped support for 32 bit hosts. If you are using a 32 bit machine, you need to use VirtualBox 5.2 instead.
Note that if you have UEFI firmware on your computer, I would recommend disabling Secure Boot, because when installing VirtualBox, there will be some kernel modules (vboxdrv, vboxnetflt, vboxnetadp, vboxpci) added to the Linux kernel.
Enable sudo for Standard User Account on Debian
Some commands in this tutorial are prefixed with sudo
. If your user account isn’t in the sudoer list, you can use the following command to switch to root user, assuming you know the root password.
su -
If you want to add the standard user account into sudoer list, run the following command as root. Replace username with your actual username.
adduser username
sudo
Then install sudo
utility.
apt install sudo
Log out and log back in for the change to take effect. From now on, the standard user can use sudo
to manage the system.
Install Latest VirtualBox 6.0.10 on Debian 10 Buster
VirtualBox isn’t included in the default Debian 10 repository, but you can install it from the upstream Oracle repository. First, create a new source list file for VirtualBox under the /etc/apt/sources.list.d/
directory, with a command line text editor such as Nano.
sudo nano /etc/apt/sources.list.d/oracle-virtualbox.list
Copy the following line and paste it in the file.
deb https://download.virtualbox.org/virtualbox/debian buster contrib
To save the file in Nano text editor, press Ctrl+O
, then press Enter
to confirm. Press Ctrl+X
to close the file. Next, run the following command to fetch the Oracle GPG public key and import it to your Debian 10 system, so packages downloaded from Oracle repository can be verified.
wget -q https://www.virtualbox.org/download/oracle_vbox_2016.asc -O- | sudo apt-key add -
Now all left to do is update local package index and install Virtualbox 6.0.10.
sudo apt update sudo apt install virtualbox-6.0
If your computer is 32 bit only, then you need to install VirtualBox 5.2 instead.
sudo apt install virtualbox-5.2
Now you can start VirtualBox from the OS applications menu (You might need to re-login for the VirtualBox icon to show up in applications menu), or by issuing the following command in terminal.
virtualbox
You can check the version number in Help
> About VirtualBox
.
VM Start Failure Troubleshooting
Sometimes you may see the following error when starting a virtual machine.
rtr3initex failed with rc=-1912 (rc=-1912) the VirtualBox kernel modules do not match this version of VirtualBox.
One of the causes is that you had previously installed VirtualBox from another repository and now you install it again from Oracle repository. In that case, you need to completely remove the residual configuration files of the previous VirtualBox. For example, I had installed Virtualbox from stretch-backports repository when the system is still Debian 9. Now the system is upgraded to Debian 10, I need to completely remove the residual configuration file with the following command.
sudo apt purge virtualbox sudo apt autoremove
Then run the following command to rebuild VirtualBox kernel modules.
sudo /sbin/vboxconfig
If you see the following error,
vboxdrv.sh: failed: Cannot change group vboxusers for device /dev/vboxdrv.
it’s probably because the vboxusers
group doesn’t exist. You can add this group with the following command:
sudo addgroup --vboxusers
Then re-run the vboxconfig
command.
If the VM still can’t start, then you might have the virtualbox-dkms
package installed on your system before upgrading to Debian 10 buster. You need to uninstall this package.
sudo apt purge virtualbox-dkms
And reinstall VirtualBox 6.0
sudo apt purge virtualbox-6.0 sudo apt install virtualbox-6.0
Advice on Using VirtualBox
- Allocating two or more CPUs to the VM and installing VirtualBox Guest Additions can significantly improve VM performance.
- When you update to a newer version of VirtualBox, you also need to upgrade VirtualBox Extension Pack and VirtualBox Guest Additions, if you have installed them.
Next Step
I hope this tutorial helped you install VirtualBox on Debian 10 Buster. You may also want to read:
As always, if you found this post useful, then subscribe to our free newsletter to get more tips and tricks. Take care 🙂
Thanks, it would worth mentioning that on vagrant boxes the following command needs to be ran “vagrant plugin update” prior to “vagrant up”, at least that was the case for me.
You are the best of the best , thx u very much ! Only u can help me !
Hi, getting the following right after the last command:
I have Debian 10.2 Buster DVD-01 on a USB stick, but looks like it doesn’t see it.
Thanks a lot for any heads up.
Why are you using DVD as the repository? If you have Internet connection, you should use online repositories.
Open the repository configuration file with a text editor.
Find the following line
Comment this line out by add a # character at the beginning of this line.
Save and close the file. The update repository and install virtualbox.
Hi Xiao, thanks so much for the prompt reply!
Not sure why that line was twice in /etc/apt/sources.list, the first instance commented out… Perhaps because I installed Buster from there?… So I dd’d the active one and :wq…
Now getting another issue:
Found this below doing a search online, but not sure it matches my issue:
Again thanks a lot.