VirtualBox remains one of the most practical ways to run multiple operating systems on a single machine without dual-booting. Oracle released VirtualBox 7.2.6 in early 2026 with improved Wayland support, better nested virtualization, and tighter integration with Oracle Cloud Infrastructure. This guide covers installation on Ubuntu 24.04, Debian 13, and Kali Linux, all from the Oracle repository so you get the latest build instead of whatever your distro ships (or doesn’t ship at all).
The three distros handle VirtualBox differently. Ubuntu 24.04 includes an older 7.0.x build in its universe repository, Debian 13 (Trixie) dropped VirtualBox from its repos entirely, and Kali Linux requires a workaround because the Oracle repository doesn’t recognize its rolling release codename. The Oracle repo gives you 7.2.6 on all three, which is what we’ll set up here.
Tested April 2026 on Ubuntu 24.04.4 LTS, Debian 13 (Trixie), Kali Linux 2026.1, VirtualBox 7.2.6 r172322 from the Oracle repository
Prerequisites
Before starting, make sure you have the following:
- Ubuntu 24.04.x LTS, Debian 13, or Kali Linux 2026.x (64-bit, AMD64 architecture)
- A user account with
sudoprivileges - A CPU with hardware virtualization support (VT-x for Intel, AMD-V for AMD). Check with:
grep -Ec '(vmx|svm)' /proc/cpuinfo - At least 4 GB RAM (8 GB or more recommended if you plan to run VMs with 2+ GB each)
- Active internet connection to download packages from the Oracle repository
Install VirtualBox from your distro’s repository
If you just want a quick installation without adding third-party repositories, Ubuntu 24.04 includes VirtualBox in the universe repository. This ships version 7.0.16, which is older but functional:
sudo apt install virtualbox
This approach works only on Ubuntu. Debian 13 removed VirtualBox from its repositories because it contains non-free components that don’t meet Debian’s licensing requirements. Kali Linux doesn’t carry its own VirtualBox package either. For these distros, or if you want VirtualBox 7.2.x on Ubuntu, use the Oracle repository as described in the next sections.
VirtualBox availability across distros
This table summarizes what each distro offers and the codename you need for the Oracle repository:
| Distro | Distro repo version | Oracle repo codename | Oracle repo version tested |
|---|---|---|---|
| Ubuntu 24.04 LTS | 7.0.16 (universe) | noble | 7.2.6-172322 |
| Debian 13 (Trixie) | Not available | trixie | 7.2.6-172322 |
| Kali Linux 2026.x | Not available | bookworm (hardcoded) | 7.2.6-172322 |
Kali Linux deserves a note here. Running lsb_release -cs on Kali returns kali-rolling, which the Oracle repository does not recognize. Since Kali is based on Debian, using bookworm as the codename works reliably.
Add the Oracle VirtualBox repository
First, remove any existing VirtualBox packages to avoid conflicts with the Oracle build:
sudo apt remove --purge virtualbox virtualbox-* -y 2>/dev/null
Install the required dependencies for repository management:
sudo apt update
sudo apt install -y curl gnupg2 software-properties-common apt-transport-https ca-certificates
Import the Oracle GPG signing key:
curl -fsSL https://www.virtualbox.org/download/oracle_vbox_2016.asc | sudo gpg --dearmor -o /usr/share/keyrings/oracle-virtualbox-2016.gpg
Now add the repository. The command differs slightly for each distro because of the codename.
Ubuntu 24.04
Ubuntu’s codename is detected automatically with lsb_release -cs:
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/oracle-virtualbox-2016.gpg] https://download.virtualbox.org/virtualbox/debian $(lsb_release -cs) contrib" | sudo tee /etc/apt/sources.list.d/virtualbox.list
This resolves to noble on Ubuntu 24.04.
Debian 13
Same approach works on Debian since the Oracle repo recognizes trixie:
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/oracle-virtualbox-2016.gpg] https://download.virtualbox.org/virtualbox/debian $(lsb_release -cs) contrib" | sudo tee /etc/apt/sources.list.d/virtualbox.list
This resolves to trixie on Debian 13.
Kali Linux
On Kali Linux, lsb_release -cs returns kali-rolling, which Oracle’s repo doesn’t have. Hardcode bookworm instead:
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/oracle-virtualbox-2016.gpg] https://download.virtualbox.org/virtualbox/debian bookworm contrib" | sudo tee /etc/apt/sources.list.d/virtualbox.list
This works because Kali is based on Debian and shares binary compatibility with Bookworm packages.
Install VirtualBox 7.2
Update the package index to pick up the new repository:
sudo apt update
Install VirtualBox 7.2:
sudo apt install -y virtualbox-7.2
The installer compiles kernel modules automatically during installation. Once complete, verify the installed version:
VBoxManage --version
The output confirms the exact build:
7.2.6r172322
Check that the kernel modules loaded correctly:
lsmod | grep vbox
You should see three modules:
vboxnetadp 28672 0
vboxnetflt 36864 0
vboxdrv 724992 2 vboxnetadp,vboxnetflt
The vboxdrv module is the core driver that enables hardware virtualization. vboxnetflt handles bridged networking and vboxnetadp creates host-only adapters. All three should be loaded.
Confirm the VirtualBox service is running:
systemctl status vboxdrv.service
The status should show active (exited), which is normal for a service that loads kernel modules and exits:
● vboxdrv.service - VirtualBox Linux kernel module
Loaded: loaded (/usr/lib/virtualbox/vboxdrv.sh; enabled; preset: enabled)
Active: active (exited)
Install the Extension Pack
The VirtualBox Extension Pack adds USB 2.0/3.0 passthrough, disk encryption, PXE boot for Intel NICs, and Oracle Cloud Infrastructure integration. It is free for personal and evaluation use.
Download the Extension Pack matching your installed version:
wget https://download.virtualbox.org/virtualbox/7.2.6/Oracle_VirtualBox_Extension_Pack-7.2.6.vbox-extpack
Verify the file integrity before installing. The SHA-256 hash for this release is eb31505e56e9b4d0fbca139104da41ac6f6b98f8e78968bdf01b1f3da3c4f9ae:
sha256sum Oracle_VirtualBox_Extension_Pack-7.2.6.vbox-extpack
The hash should match:
eb31505e56e9b4d0fbca139104da41ac6f6b98f8e78968bdf01b1f3da3c4f9ae Oracle_VirtualBox_Extension_Pack-7.2.6.vbox-extpack
Install the pack with VBoxManage. The --accept-license flag requires the SHA-256 hash of the license text:
sudo VBoxManage extpack install --replace --accept-license=eb31505e56e9b4d0fbca139104da41ac6f6b98f8e78968bdf01b1f3da3c4f9ae Oracle_VirtualBox_Extension_Pack-7.2.6.vbox-extpack
A successful installation prints:
0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%
Successfully installed "Oracle VirtualBox Extension Pack".
Confirm the Extension Pack is registered:
VBoxManage list extpacks
The output shows the pack details:
Extension Packs: 1
Pack no. 0: Oracle VirtualBox Extension Pack
Version: 7.2.6
Revision: 172322
Edition:
Description: Oracle Cloud Infrastructure integration, PXE ROM.
VRDE Module: VBoxVRDP
Crypto Module: VBoxPuelCrypto
Usable: true
Why unusable:
Clean up the downloaded file:
rm -f Oracle_VirtualBox_Extension_Pack-7.2.6.vbox-extpack
Add your user to the vboxusers group
VirtualBox creates a vboxusers system group during installation. Your user account must be a member of this group to access USB devices from within a VM and to use host-only networking:
sudo usermod -aG vboxusers $USER
Verify the group membership:
groups $USER
You need to log out and back in (or reboot) for the group change to take effect. Until then, USB passthrough won’t work even though VirtualBox itself will launch fine.
Create your first VM
You can launch VirtualBox from the application menu, but here’s a quick command-line example to create and configure a VM. This is useful for scripting or headless servers.
Create a new VM named “TestVM”:
VBoxManage createvm --name "TestVM" --ostype Ubuntu_64 --register
Allocate 2 GB of RAM and 2 CPU cores:
VBoxManage modifyvm "TestVM" --memory 2048 --cpus 2 --nic1 nat
Add a SATA controller and attach a 20 GB virtual disk:
VBoxManage storagectl "TestVM" --name "SATA" --add sata --controller IntelAhci
VBoxManage createmedium disk --filename ~/VirtualBox\ VMs/TestVM/TestVM.vdi --size 20480
VBoxManage storageattach "TestVM" --storagectl "SATA" --port 0 --device 0 --type hdd --medium ~/VirtualBox\ VMs/TestVM/TestVM.vdi
Attach an ISO to the virtual DVD drive for installation:
VBoxManage storagectl "TestVM" --name "IDE" --add ide
VBoxManage storageattach "TestVM" --storagectl "IDE" --port 0 --device 0 --type dvddrive --medium /path/to/your.iso
Start the VM (use gui for a desktop environment, headless for servers):
VBoxManage startvm "TestVM" --type gui
To list all registered VMs and their current state:
VBoxManage list vms
VBoxManage list runningvms
If you want to run a Kali Linux VM, grab the official ISO from kali.org and follow the same pattern. Set the OS type to Debian_64 since VirtualBox doesn’t have a dedicated Kali type.
Troubleshooting
These are real errors encountered during testing on all three distros.
modprobe: FATAL: Module vboxdrv not found in directory
This happens when the kernel headers for your running kernel are not installed. VirtualBox compiles its kernel modules during package installation, and without matching headers, the build silently fails. Install the headers and rebuild:
sudo apt install -y linux-headers-$(uname -r)
sudo /sbin/vboxconfig
The vboxconfig script recompiles all VirtualBox kernel modules. After it completes, load the driver manually to confirm:
sudo modprobe vboxdrv
If it returns without output, the module loaded successfully.
Secure Boot: required key not available
On systems with UEFI Secure Boot enabled, unsigned kernel modules are blocked from loading. VirtualBox’s vboxdrv module is not signed by a key trusted by the UEFI firmware. You have two options.
The simpler approach is to disable Secure Boot in BIOS/UEFI settings. Reboot, enter firmware setup (usually F2, F12, or DEL during POST), find the Secure Boot option, and set it to Disabled.
If you need to keep Secure Boot enabled, sign the VirtualBox modules with a Machine Owner Key (MOK). Generate a key pair:
sudo mkdir -p /root/module-signing
cd /root/module-signing
openssl req -new -x509 -newkey rsa:2048 -keyout MOK.priv -outform DER -out MOK.der -nodes -days 36500 -subj "/CN=VirtualBox Module Signing/"
Enroll the key with the MOK manager:
sudo mokutil --import /root/module-signing/MOK.der
This prompts for a one-time password. After rebooting, the MOK Manager appears in the boot sequence where you enter that password to enroll the key. Then sign each module:
for module in vboxdrv vboxnetflt vboxnetadp; do
sudo /usr/src/linux-headers-$(uname -r)/scripts/sign-file sha256 /root/module-signing/MOK.priv /root/module-signing/MOK.der $(modinfo -n $module)
done
Reload the modules after signing:
sudo modprobe vboxdrv
WARNING: The vboxdrv kernel module is not loaded
VirtualBox prints this at startup when the kernel module compiled during installation no longer matches the running kernel. This typically happens after a kernel update where you rebooted into the new kernel but didn’t recompile the modules:
sudo /sbin/vboxconfig
This rebuilds all VirtualBox kernel modules against the currently running kernel. You can also set up DKMS so the modules recompile automatically on every kernel update:
sudo apt install -y dkms
sudo /sbin/vboxconfig
VT-x is not available (VERR_VMX_NO_VMX)
This error means another hypervisor has locked the CPU’s virtualization extensions. On Linux, KVM is the usual culprit. If you don’t need KVM while using VirtualBox, unload its modules:
sudo modprobe -r kvm_intel kvm
On AMD systems, the module is kvm_amd instead of kvm_intel:
sudo modprobe -r kvm_amd kvm
To prevent KVM from loading at boot, blacklist it:
echo -e "blacklist kvm\nblacklist kvm_intel\nblacklist kvm_amd" | sudo tee /etc/modprobe.d/blacklist-kvm.conf
sudo update-initramfs -u
If you need both KVM and VirtualBox on the same machine, you’ll have to switch between them by loading one set of modules and unloading the other. They cannot share the CPU’s VT-x extensions simultaneously.