Install VirtualBox Guest Additions on Debian Linux to View Guest OS in Full Screen

When you first install Debian in VirtualBox you can’t adjust the size of the guest OS. In order to be able to adjust the screen size of the guest OS you must install VirtualBox Guest Additions on the guest OS. This will allow you to use the guest OS just like you were using a normal OS.

Here is how to do this:

  • log in as root or with an account that has root privileges
  • update & upgrade the system
apt-get update && apt-get upgrade
  • install required packages for building kernel modules
apt-get install dkms build-essential module-assistant linux-headers-$(uname -r)
  • prepare your system for building kernel modules
m-a prepare
  • download the same version of VirtualBox Guest Additions that matches your VirtualBox version.
  • in the virtual machine window go to Devices -> Insert Guest Additions CD image …
  • mount the CD
mount /media/cdrom
  • run the VboxLinuxAdditions.run script
sh /media/cdrom/VboxLinuxAdditions.run
  • restart Debian

Important Note:

  • Do not Enable 3D Acceleration in Settings > Display. After installing the VirtualBox Linux Additions, the dispaly manager will crush and you won’t be able to see anything on the screen.