Demonstrated on Parrot Security OS VirtualBox virtual machine (VM) but should work for most Debian based OS, such as Kali Linux. Article uses Windows host but process is similar on MacOS and Linux hosts. Also assumes that you have VirtualBox and Parrot Security OS installed on host system. If not, check out Install Parrot Security OS on VirtualBox using ISO. Derived from documentation found on virtualbox.org and linuxize.com.
VirtualBox Guest Additions ISO is included with the installation files for VirtualBox. As such, you can find these in the installation folders within your file system. There is no need to download separately at the time of writing this post.
Mount VBoxAdditions to Parrot Security OS VM
While VM is turned off and selected, click on Storage to access Storage settings.
Click on the CD icon under the Controller: IDE. This will be where you mount the VirtualBox Additions ISO. Click on CD next to the optical drive drop down menu. You should see the following menu, although, you may not have the same options as I have already installed it on other VMs. Select Choose a disk file…
C:\Program Files\Oracle\VirtualBox, select VBoxGuestAdditions and click Open.
The VBoxGuestAdditions.iso should now be mounted to your VirtualBox IDE controller.
Install VirtualBox Guest Additions to Parrot Security OS VM
Start your Parrot OS VM, sign in, open a terminal window and enter the following:
sudo apt update && sudo apt upgrade
This will update your Parrot Security OS.
Next, enter the following command to install the packages required for building kernel modules:
sudo apt install build-essential dkms linux-headers-$(uname -r)
Next, we’ll mount the VirtualBox Additions ISO to our guest OS. To mount the ISO, create a new directory and mount the ISO with the following commands:
sudo mkdir -p /mnt/cdrom
sudo mount /dev/cdrom /mnt/cdrom
Navigate to the /mnt/cdrom directory and run the Linux script to install the Guest Additions:
sudo sh ./VBoxLinuxAdditions.run --nox11
The –nox11 option tells the script to not open an xterm window.
Restart your VM for the install to complete.
sudo shutdown -r now
To confirm that installation was successful, login, open a terminal and type the following command:
lsmod | grep vboxguest
The output should look something like this:
If you receive no output, the installation was not successful and you’ll want to run through the commands again.
You have now installed VirtualBox Guest Additions which will allow you to resize the guest OS window, adds Drag and Drop support, improves performance and more. For more information, visit the VirtualBox documentation page.