In case we have installed the OSE edition of Virtual Box from the repositories we can add the guest additions from the repositories in the guest. This will install guest additions matching the Virtual Box version as obtained from the repositories. It is not recommended to install these in newer releases of Virtual Box as obtained from the Oracle repository (see below).
The .iso file with an image of the OSE edition of the guest additions CD will install in the host directory /usr/share/virtualbox/VBoxGuestAdditions.iso. Mount this .iso file as a CD in your virtual machine's settings. In the guest you will then have access to a CD-ROM with the installer.
In case the Guest Additions fail to build we may have to install the Linux kernel headers (see How do I install kernel header files?) or build-essential tools in addition. It is also recommended to have dkms installed (see below - Note 4). You can run this command in a terminal to install both:
Selecting Devices -> Install Guest Additions (or press Host+D from the Virtual Box Manager) the Guest Additions CD .iso will be loaded but not installed in your guest OS. To install we need to run the installer script VBoxLinuxAdditions.run as root or from the Autorun Prompt (see below).
Next step is to run the autorun.sh script (as root) on this mounted CD by opening the drive and clicking on the "Run Software" button. This will build and install the vbox kernel modules needed.
Note 2
In some systems the Virtual Box Guest Additions CD icon may not be shown on the desktop, but will be accessible from the Places menu. If the CD still was not there you may have to manually add the VBoxGuestAdditions.iso as a CD-ROM in the Virtual Box Manager Storage menu. In an Ubuntu host the disk image is in /usr/share/virtualbox/VBoxGuestAdditions.iso.
Note 3
In some systems (e.g. when running Xubuntu guests) we may not have an Autorun Prompt for the mounted CD. Then we can install the guest additions by opening a terminal on the mounted guest additions .iso to run sudo ./VBoxLinuxAdditions.run. In Lubuntu or Ubuntu Server guests we additionally need to install the GNU C compiler (gcc ) and the make utility in the guest system to be able to compile the guest additions.
Note 4
Running DKMS in the guest OS will keep Guest Additions installed after a guest kernel update. It is not a prerequisite for Guest Additions but if used it should be installed before we install the Guest Additions.
In case Guest Additions are not installed properly we may not be able to boot to the GUI. In this case we need to boot holding the Shift key to access the Grub menu where we access a root shell as depicted in the following question (we do need to mount the filesystem read/write to proceed):
In case something went wrong with installing the guest additions, or the guest OS can not boot after installing we may have to remove the additions. This can also be done from a root shell by running an uninstallation script located in the guest /opt directory.
This found and updated the correct version of the VirtualBox Guest Additions and my system seems to work properly again, and I'm assuming this will also work if Guest Additions are failing to install from the menu item.
Here are the steps I ran which finally worked, but as user named 'pcworld' stated above it may have been the case that only the last command was actually required. I'll never know, but I want to share in case this helps anyone else:
The virtualbox-guest-additions package has to be installed. Furthermore, it may appear that nothing has happened, but all the "Install Guest Additions" button do is mounting the cdrom. You should open the File manager (Nautilus / Dolphin), select the "CD device" and run the installer.
If the VBOXADDITIONS cd does not pop up in File Manager, Use File Manager to open the contents of the VBOXADDITIONS cd, then open a terminal there, by going to File Manager's menu and selecting 'Open Current Folder in Terminal'
Una vez que hayas instalado Ubuntu en VirtualBox, es posible que desees agregar algunos extras para mejorar la experiencia de usuario y la funcionalidad. Una de las cosas que puedes hacer es instalar las Guest Additions de Ubuntu.
Algunas de las caractersticas que proporcionan incluyen la integracin del portapapeles, la capacidad de ajustar el tamao de la pantalla automticamente y la posibilidad de compartir carpetas entre el sistema operativo host y el sistema operativo invitado, por lo que veis aadir guest additions ubuntu se vuelve algo imprescindible si queremos sacar el 100% del sistema operativo invitado, en este caso Ubuntu..
Una vez que se haya completado la instalacin, reinicia la mquina virtual. Despus de reiniciar, deberas notar una mejora en la funcionalidad y el rendimiento de la mquina virtual, como la capacidad de ajustar el tamao de la pantalla automticamente y la integracin del portapapeles.
www.linuxtechi[.]com/install-virtualbox-guest-additions-on-rhel/
www.linkedin[.]com /pulse/installing-virtualbox-guest-additions-centosrhel-enhanced-soran
forums.virtualbox[.]org /viewtopic.php?t=1091421
technixleo[.]com /install-and-use-virtualbox-on-centos-rhel/
kifarunix[.]com /install-virtualbox-guest-additions-on-rocky-linux-9/
With that said, this worked fine for myself. I was not able to replicate your issue with a standard installation of Rocky Linux. In my case, I used the XFCE desktop. GNOME (Workstation) and others should work the same way.
So, the short version of this long story is that GA seems to have installed, at least partially, but with some problems. There still are errors during compiles for the GA installation yet some of it works.
If you are continuing to have issues, I would suggest uninstalling all the drivers, rebooting, and trying to install them again. You could also start clean and just reinstall Rocky Linux 9 entirely to the VM and run through the installation steps for the guest additions.
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.
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.
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.
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.
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.
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
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.
Guest Additions es un software proporcionado por VirtualBox que engloba una serie de aplicaciones y controladores para mejorar la integracin y funcionalidades del sistema operativo husped, en el presente caso Ubuntu/Kubuntu y otras distribuciones derivadas. Por tanto, hay que instalarlo en cada una de las mquinas virtuales que creemos con Virtualbox en nuestro sistema operativo anfitrin, que puede ser cualquier distribucin GNU/Linux o Windows.
Este software aporta al sistema husped, entre otras, una mejor integracin del cursor del ratn; comunicacin entre el sistema anfitrin y el husped, lo que supone sincronizacin horaria, directorios y unidades de disco compartidos, portapapeles compartido y la funcin arrastrar y soltar; mejor soporte de vdeo, modo de pantalla completa y redimensionamiento de la maquina virtual como si de una ventana cualquiera se tratara, etc.
Esto es una de las primeras faenas que podemos acometer para comprobar que las Guest Additions est funcionando. Arrancamos el sistema huesped con VirtualBox. Con el puntero del ratn redimensionamos la ventana a nuestro gusto como si se tratara de cualquier ventana en el sistema anfitrin, incluso podemos maximizar a pantalla completa.
d3342ee215