How to install VirtualBox on Kali Linux


The first thing we are going to do is import VirtualBox’s repository key:
wget -q -O- | sudo apt-key add –

One thing to bare in mind, Kali Linux is based on Debian, so we need to use Debian’s current stable version. At the time of writing, its “buster”:
echo “deb [arch=amd64] buster contrib” | sudo tee /etc/apt/sources.list.d/virtualbox.list

As we have altered our network repository, we need to re-build the cache.
sudo apt update

As VirtualBox has various kernel modules (e.g. vboxdrv, vboxnetflt and vboxnetadp), we need to make sure they are kept up-to-date when Kali’s kernel gets updated. This can be achieved using dkms.

sudo apt install -y dkms

Now its time to install VirtualBox itself (along with its Extension Pack to expand VirtualBox’s advanced features):

sudo apt install -y virtualbox virtualbox-ext-pack

When prompted, read and accept the license.

You can now find VirtualBox in the menu or start it via the command line:



Please enter your comment!
Please enter your name here