Installing VirtualBox on Kali (Host)

Installing VirtualBox on Kali (Host)

To install VirtualBox on Kali Linux, follow these steps:

  1. Make sure your Kali Linux is up-to-date:
sudo apt update
sudo apt full-upgrade -y
  1. Import VirtualBox repository key:
curl -fsSL https://www.virtualbox.org/download/oracle_vbox_2016.asc|sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/oracle_vbox_2016.gpg
curl -fsSL https://www.virtualbox.org/download/oracle_vbox.asc|sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/oracle_vbox.gpg
  1. Add VirtualBox repository:
echo "deb [arch=amd64] https://download.virtualbox.org/virtualbox/debian bullseye contrib" | sudo tee /etc/apt/sources.list.d/virtualbox.list
  1. Update package cache and install dkms:
sudo apt update
sudo apt install dkms
  1. Install VirtualBox and Extension Pack:
sudo apt install virtualbox virtualbox-ext-pack
  1. Accept the license and wait for installation to complete.

  2. You can start VirtualBox using:

virtualbox
  1. The VirtualBox kernel modules will be automatically updated when the Kali Linux kernel is updated, thanks to dkm.

That's how you can install VirtualBox on Kali Linux as a host to run virtual machines. Let me know if you have any other doubts!