Install VirtualBox Guest Additions in Linux Mint Step by Step
In this tutorial I will show you how to install VirtualBox guest additions in Linux Mint virtual machine. To follow this tutorial, you need to have Linux Mint installed inside VirtualBox as a guest OS. I’m using Debian 10 Buster as the host OS, but the following method works for any host OS (including MacOS and Windows).
What is VirtualBox Guest Additions?
VirtualBox guest additions provide the following capabilities:
- Enable users to seamlessly move mouse pointer between host and guest OS.
- Allow guest OS to have read and write access to hard drives on the host OS, so you can transfer files between them.
- Power up the graphics/video ability of the guest OS. The screen resolution of guest OS can be automatically adjusted and 3D graphics can be accelerated.
- Enable bidirectional shared clipboard between host and guest OS, so you can copy and paste stuff between them.
How to Install Virtualbox Guest Additions in Linux Mint
Log into Linux Mint (guest OS) and run the following command in a terminal window to update software packages.
sudo apt update sudo apt upgrade
Please note that if a new Linux kernel is installed in the upgrade process, then you need to reboot Linux Mint virtual machine. After that, run the following command to install required packages for building kernel modules.
sudo apt install build-essential module-assistant
Next, prepare Linux Mint for building kernel module with the following command.
sudo m-a prepare
Then in the VirtualBox window menu bar, select Devices > Insert Guest Additions CD image.
If your host OS already has the CD image, then you will be asked if you want to run the software. Select Run.
Then you will need to enter your password in order to install the guest additions.
Output in terminal window.
Verifying archive integrity... All good. Uncompressing VirtualBox 6.0.10 Guest Additions for Linux........ VirtualBox Guest Additions installer Copying additional installer modules ... Installing additional modules ... VirtualBox Guest Additions: Starting. VirtualBox Guest Additions: Building the VirtualBox Guest Additions kernel modules. This may take a while. VirtualBox Guest Additions: To build modules for other installed kernels, run VirtualBox Guest Additions: /sbin/rcvboxadd quicksetup <version> VirtualBox Guest Additions: or VirtualBox Guest Additions: /sbin/rcvboxadd quicksetup all VirtualBox Guest Additions: Building the modules for kernel 4.15.0-55-generic. update-initramfs: Generating /boot/initrd.img-4.15.0-55-generic VirtualBox Guest Additions: Running kernel modules will not be replaced until the system is restarted Press Return to close this window...
Once the guest additions is installed, press Enter
to close the terminal window and restart your Linux Mint virtual machine. Now the resizeable display should be working. The screen resolution of Linux Mint VM will adjust with the size of VirtualBox window. You can press right Ctrl and F keyboard shortcut to enter full-screen mode. You can now also configure shared folder and bidirectional shared clipboard.
If VirtualBox Can’t Find the Guest Additions CD Image
If your host OS doesn’t have the guest additions CD image, then it will ask you to click a button to download the CD image onto the host OS. Click Download.
If you can’t download it from the above window, then go to http://download.virtualbox.org/virtualbox/. Select a version and download VBoxGuestAdditions ISO to your home directory. Once downloaded, insert the ISO image. If you see the following error, click Force Umount.
Enable Copy and Paste Clipboard Between Host and Guest
After installing guest additions, you can go to the virtual machine settings
-> General
-> Advanced
and enable bidirectional clipboard.
Enable Shared Folder
Now you can also share files between host and guest OS via the shared folder feature. Go to the virtual machine settings. In the left pane, select Shared Folders
. Then click on the add
button to add a shared folder.
- In the
Folder Path
field, select a folder on your host OS. - Tick on the
Auto-mount
checkbox so that the shared folder will be automatically mounted to the guest OS when virtual machine boots up. - In the Mount-point field, enter a path on the guest OS, such as a sub-directory in your user’s home directory.
- Tick on the
Make Permanent
checkbox.
After saving the settings, you will find the shared folder appears in your home directory in the Linux Mint virtual machine, but only the root user and members of the vboxsf group have read and write access to this shared folder. So what we need to now is add your user to vboxsf group. Open up a terminal in Linux Mint and run the following command. Replace username with your real username.
sudo adduser username vboxsf
Log out of the current session and log back in. Now you should be able to access the shared folder.
Wrapping Up
I hope this tutorial helped you install VirtualBox guest additions in Linux Mint. You may also want to read:
- Virtualbox Bridged Networking Mode Allows VM to Connect to Your Router
- How to Access USB from VirtualBox Guest OS
As always, if you found this post useful, then subscribe to our free newsletter to get more tips and tricks. Take care 🙂
You know how it goes, looking around the net for answers because, perhaps, installs you have done before with ease suddenly produce a problem.
For me, installing Guest Additions on Mint.
So I find your information and my problem suddenly becomes a breeze to sort.
Thank you so much for your most professional guidance.
Other sites had directions for earlier versions of Mint. These directions worked perfectly for Mint Cinnamon x64 19.2. I especially appreciated finding the:
sudo adduser username vboxsf
command for accessing shared folders. Other sites left that out and a novice to Linux would not know to employ that command in Terminal.
Nicely done!
the auto-run prompt is NOT appearing when I insert the guest additions CD image
Good tutorial, I have a confucion, the packages build-essential and module-assistant are installed in the guest system or in the main system?
In the beginning of this article, I said “The following method works for any host OS (including MacOS and Windows)”. This indicates that the following command should be executed in the guest OS.
Great tutorial! Thank you.
I have been having problems with this all day. I’ve updated Virtualbox and components, and un and reinstalled guest additions AND my Mint VM several times but I still cannot resize my Mint screen to fill. The VM recognizes and installs guest additions fine but nothing is working. I’ve searched forums for the last two hours and no one has any other suggestions besides ‘install guest additions on Virtualbox’.
Does anyone have any ideas? Please?
And of course as soon as I post this I found the problem…
If you hear of anyone else having this issue, tell them to make sure the Auto-Resize Guest Display option in View menu of Virtualbox window is checked.
Then in the VirtualBox window menu bar, select Devices > Insert Guest Additions CD image.
when I do this, linux mint does not respond. I am using the XFCE version?
What should i do to do it manuall
First, find out where the file VBoxGuestAdditions.iso is on your system. For me it is in:
/usr/share/virtualbox/VBoxGuestAdditions.iso
From the VirtualBox menu choose:
Devices -> Optical Drives -> Choose/Create a disk image…
Click Add and select the VBoxGuestAdditions.iso file that you found on your system.
** The following assumes you’re guest OS is Windows 10 **
Open the Windows file browser.
Go to “This PC” and you should see “CD Drive (D:) VirtualBox Guest Additions”
Open that and double click on the VBoxWindowsAdditions file.
After confirming you’re happy for it to make changes (this is only in the guest OS), it should install the additions and reboot.
install xterm and install through xterm
I have Mint 19.3 running VB 5.2.34, with Win7 installed on my laptop. I also have Mint 20 running VB 6.1, with Win 7 installed on my desktop. Both system have similar problem, the usb port is not available. Guest Additions has been install on both with accessing shared folders and resizing of Win desktop work correctly. Any suggestions? thanks Carl
Thanks for your informative site. Just used to install Linux Mint 19.3 (Ver 4.4.5) within Oracle Virtual Box on my host iMac. Using this VM to learn Linux and complete upcoming fall semester assignments.
I jumped the gun in trying to install Guest Additions. Needed to delete initial Linux install and start from scratch. Following your directions worked well.
Also, appreciated your instructions to enable both clipboard and shared folder. Moving on to your “Bridged Networking Mode” instructions.
Thanks man i really needed this input, my problem was different, it just would not run the virtual guest addditions, so i ran the script in terminal, but your explainations made me realise this. Im happy the results are the same, i face one last challange my usb ports just wont work no matter what, but i got an idea.. anyway, cheers
Thank you linuxbabe your instructions worked perfectly. I am running Linux Mint Mate 20 as a guest OS.
Great instructions. Thank you very much!
devices isnt popping up is it because virtualbox is updated?
newbie here-I googled a lot and watched a bunch of youtube videos but could not solve my problem of guest additions not working after installation of ubuntu and its associated guest additions , then i tried mint, did not work in the beginning after installing of guest add.
Then i stumbled this site searching for resolution, followed your instructions and it worked, then i went back and tried in ubuntu again and it worked there too, got my full screen in both, feel so much better to work on a full screen.
Thankyou very much for helping the community.
This tutorial doesn’t work.
Very clear and accurate. Much appreciated!
Excellent tutorial, many thanks!