VirtualBox Guest Additions on Fedora 34/33, CentOS/RHEL 8/7/6/5 - Comment Page: 8

This is guide, howto install Oracle VirtualBox Guest Additions on Fedora, CentOS and Red Hat (RHEL). This guide should work with Fedora 34/33/32/31/30, CentOS 8.2/7.8/6.10/5.11, Red Hat (RHEL) 8.2/7.8/6.10/5.11. VirtualBox Guest Additions is special software that can be installed inside Linux virtual machines to improve performance and make integration much more seamless. Among the features provided by these VirtualBox Guest Additions are mouse pointer integration and arbitrary screen solutions (e.g. by resizing the guest window). Check video version of guide: Watch More Videos and Subscribe to if-not-true-then-false.com Youtube Channel Note: Fedora 34/33/32/31/30...

352 comments on “VirtualBox Guest Additions on Fedora 34/33, CentOS/RHEL 8/7/6/5 - Comment Page: 8

1 6 7 8 9 10 15
    1. Thanks for the great site. I don’t know who you are but you’ve done a great job providing a lot of very useful information. Thanks for all your time and effort.

      Reply
    2. You might want to point out in step 6 that if you’re installing guest additions on Fedora server (and I assume server versions of the other distributions) then the output will be slightly different. I got a message that I didn’t save that the windows and graphics installation would be skipped because no X system was found and the installation would be skipped. It was a bit confusing because the output just terminated at that and I didn’t get the notice to reboot. After rebooting, though, I found that my host shared folder was mounted and I could copy files onto my server.

      Thanks for a great document.

      Reply
    3. Thanks s lot!
      For CentOS 7, at least a GUI-less infrastructure server, this was sufficient:

      yum update kernel*
      yum install gcc kernel-devel bzip2
      KERN_DIR=/usr/src/kernels/`uname -r`
      export KERN_DIR
      mkdir /media/cdrom
      mount -r /dev/cdrom /media/cdrom
      cd /media/cdrom
      ./VBoxLinuxAdditions.run

      reboot

      So it was a bit easier, I did not need kernel-headers, dkms, perl nor the epel rpm .
      dkms was even unknown in my CentOS7.
      kernel-headers were already included in kernel-devel

      Reply
    4. hi
      how to install virtualbox guest additions 5.0.4 in fedora 23 workstation beta ?
      I try many times but i don’t succeed : i have this message “Warning : unsupported pre-release version of X.Org Server installed. Not installing the X.Org drivers.”

      Any ideas please ?

      Reply
    5. For some reason my fedora did not use kernel 4.2.3 but uses 4.0.4.
      “dnf install kernel-devel” installs headers for 4.2.3
      therefore vboxaddition build fails.
      Command:
      dnf install “kernel-devel-$(uname -r)”
      worked for me as fix.

      However I’m still amazed that very fresh install of fedora uses older kernel and uses newer as backup.

      Reply
      • Ok, I got it. I missed “reboot” command after “dnf update kernel”.

        Thats why I was still running on older kernel than actually installed.

        Reply
    6. Hi, I’m having issues installing guest additions on my Fedora 23 virtual machine. I am able to run ./VBoxLinuxAdditions.run but I get the following error message:

      “Warning: unsupported pre-release version of X.Org Server installed. Not installing the X.Org drivers”

      Everything else seems to work well, but when I reboot nothing has changed. The max resolution I can get is 1024 x 768. My host machine is a Surface Book (3,000 x 2,000 resolution) so the VM is way too small.

      If you could offer any tips, I’d really appreciate it. Thank you.

      Reply
      • Hi Pamela,

        You can downgrade Xorg back to 1.17 using following “command” (copy+paste all rows at once as root):

        
        URL="http://rpms.if-not-true-then-false.com/fedora23-old-xorg/"
        ARCH=$(uname -m)
        PACKAGES=( \
        	'xorg-x11-drv-ati-7.6.0-0.1.20150709git95f5d09.fc23' \
        	'xorg-x11-drv-evdev-2.9.2-2.fc23' \
        	'xorg-x11-drv-fbdev-0.4.3-22.fc23' \
        	'xorg-x11-drv-intel-2.99.917-15.20150729.fc23' \
        	'xorg-x11-drv-libinput-0.14.0-1.fc23' \
        	'xorg-x11-drv-openchrome-0.3.3-16.fc23' \
        	'xorg-x11-drv-nouveau-1.0.11-4.fc23' \
        	'xorg-x11-drv-qxl-0.1.4-3.fc23' \
        	'xorg-x11-drv-synaptics-1.8.2-3.fc23' \
        	'xorg-x11-drv-vesa-2.3.2-22.fc23' \
        	'xorg-x11-drv-vmmouse-13.1.0-1.fc23' \
        	'xorg-x11-drv-vmware-13.0.2-9.20150211git8f0cf7c.fc23' \
        	'xorg-x11-drv-wacom-0.30.0-2.fc23' \
        	'xorg-x11-server-Xorg-1.17.2-2.fc23' \
        	'xorg-x11-server-Xwayland-1.17.2-2.fc23' \
        	'xorg-x11-server-common-1.17.2-2.fc23' \
        )
        printf "$URL%s.$ARCH.rpm " "${PACKAGES[@]}" |xargs dnf install -y
        

        I wrote this command for users who want to install nVidia drivers on Fedora 23, but should also work with VirtualBox Guest Additions. Add also exclude=xorg-x11* to /etc/dnf/dnf.conf like:

        
        [main]
        gpgcheck=1
        installonly_limit=3
        clean_requirements_on_remove=true
        exclude=xorg-x11*
        

        Then run ./VBoxLinuxAdditions.run again.

        Reply
      • Or maybe upgrade VirtualBox.
        I have VirtualBox 5.0.10 and the guest additions that belong to that version installed without problems (using the instructions above) on Fedora 23 Workstation (for which I am grateful!). While initially also limited to 1024×768, I now run at 1680×1050, the size of my second monitor.

        Reply
        • Upgraded to Virtualbox 5.0.20, the guest additions that ships with that version worked without issue. Thanks so much!

          Reply
    7. Hi JR, I can’t see the comment that you posted in response to my concerns about the older version of xorg, but I got it in my email and I just want to say – it works! Finally! My VM is usable at last. Thank you for providing continuous support to your readers.

      Reply
      • Hi Pamela,

        You are welcome and nice to hear that you got it working!

        It’s caused by the cache that you couldn’t see my comment. If you have cookie which tells to the web server that you are commented something, then you should see live version otherwise you see cached version.

        Reply
    8. Hi
      Thank you for providing this guide. I have followed all of the steps above but still can’t seem to get GuestAdditions up and running.

      I am running VirtualBox 5.0.12 with CentOS 7

      After completing all above steps, below is what I see during Vbox install, notice there is no “main Guest Additions modules, shared folder or opengl modules. Anything I am missing? Also how to I get X.Org to be available? haven’t been able to find how/where to install?

      [[email protected] VirtualBoxAdditions]# ./VBoxLinuxAdditions.run
      Verifying archive integrity… All good.
      Uncompressing VirtualBox 5.0.12 Guest Additions for Linux…………
      VirtualBox Guest Additions Installer
      Removing Installed version 5.0.12 of VirtualBox Guest Additions…
      Removing existing VirtualBox DKMS kernal modules[ OK ]
      Removing existing VirtualBox non-DKMS kernal modules[ OK ]
      Copying additional installer modules …
      Installing additional modules …
      Removing existing VirtualBox DKMS kernal modules[ OK ]
      Removing existing VirtualBox non-DKMS kernal modules[ OK ]
      Building the VirtualBox Guest Additions kernel modules[ OK ]
      Doing non-kernel setup of the Guest Additions[ OK ]
      You should restart your guest to make sure the new modules are actually used

      Installing the Window System drivers
      Could not find the X.Org or XFree86 Window System, skipping.
      [[email protected] VirtualBoxAdditions]#

      Reply
      • Hi Michael,

        Do you have any graphical environment installed? Looks like, that you don’t have X installed? If you don’t have it, then you don’t need Window system drivers.

        Reply
        • Thanks, that was my problem. Once I installed that, all was working fine. Thank you!!

          Reply
      • Hi Suresh,

        I just tested this on CentOS 7.2 and it’s working normally for me. Some reason your log paste is expired.

        Reply
        • Thanks JR – will try again.

          Reply
    9. This worked !!!!!!!. I struggled and spend more time resolving. After making the changes, i got bad interpreter: Permission denied when executed as below

      ./VBoxLinuxAdditions-x86.run
      bash: ./VBoxLinuxAdditions-x86.run: /bin/sh: bad interpreter: Permission denied

      but by executing sh ./VBoxLinuxAdditions-x86.run

      it worked.

      Reply
    10. Thank you, thank you, thank you! I had tried hacking on the kernel source, etc as suggested by other posts in the blogosphere. CentOS 6.7 just would not compile the OpenGL modules.

      This method worked flawlessly.

      Reply
    11. Hi
      I am running Fedora23 with Virtual Box installed as per your instructions.
      When I run ./VBoxLinuxAdditions.run, I get a fail ;
      Building main Guest Additions module…….fail!
      (Look at /var/log/vboxadd-install.log to find out what went wrong)

      /tmp/vbox.0/Makefile.include.header:97: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR= and run makefile again.
      What does this mean and how do I fix it please?

      Reply
      • Hi John,

        Did you installed all packages on step 4.?

        Could you also post output of following command:

        
        rpm -qa kernel\*
        
        Reply
        • Hi JR
          here is the result
          [[email protected] ~]# rpm -qa kernel\*
          kernel-devel-4.4.4-301.fc23.i686
          kernel-modules-4.2.3-300.fc23.i686
          kernel-core-4.4.4-301.fc23.i686
          kernel-4.2.3-300.fc23.i686
          kernel-core-4.2.3-300.fc23.i686
          kernel-4.4.4-301.fc23.i686
          kernel-headers-4.4.4-301.fc23.i686
          kernel-modules-4.4.4-301.fc23.i686
          [[email protected] ~]#

          Reply
        • I installed the packages in step 4;
          [[email protected] ~]# dnf install gcc kernel-devel kernel-headers dkms make bzip2 perl
          Last metadata expiration check performed 0:07:45 ago on Mon Mar 14 11:44:16 2016.
          Package gcc-5.3.1-2.fc23.i686 is already installed, skipping.
          Package kernel-devel-4.4.4-301.fc23.i686 is already installed, skipping.
          Package kernel-headers-4.4.4-301.fc23.i686 is already installed, skipping.
          Package dkms-2.2.0.3-31.git.7c3e7c5.fc23.noarch is already installed, skipping.
          Package make-1:4.0-5.1.fc23.i686 is already installed, skipping.
          Package bzip2-1.0.6-19.fc23.i686 is already installed, skipping.
          Package perl-4:5.22.1-351.fc23.i686 is already installed, skipping.
          Dependencies resolved.
          Nothing to do.
          Complete!
          [[email protected] ~]#

          Reply
          • Thanks, could you also post output of following commands:

            
            uname -a
            
            ls -la /usr/src/kernels/
            
            Reply
    12. Hi JR
      I installed Fedora23 on a 32bit system and instead VirtualBox as per your instructions. When I installed the vbox guest additions and ran ./VBoxLinuxAdditions.run I got a fail on building main guest additions. I checked the install log and it said couldn’t find the source of the current kernel.

      Reply
    13. uname -a
      Linux localhost.localdomain 4.4.4-301.fc23.i686 #1 SMP Fri Mar 4 18:21:35 UTC 2016 i686 i686 i386 GNU/Linux

      ls -la /usr/src/kernels/
      total12
      drwxr-xr-x. 3 root root 4096 Mar 14 16:26 .
      drwxr-xr-x. 4 root root 4096 Mar 14 17:12 . .
      drwxr-xr-x. 23 root root 4096 Mar 14 16:26 4.4.4-301.fc23.i686

      also, when Fedora home screen comes up after booting I get a meesage at the top of the scree saying : “Oops sorry the 4.4.4-301.fc23.i686 boot-image has crashed,. Please contact the developer”

      Reply
      • p.s. Fedora 23, VB 5.0.20

        Reply
        • Hi TestUser,

          Could you post output of following commands:

          
          uname -a
          
          rpm -qa kernel\* |sort -V
          
          Reply
1 6 7 8 9 10 15

Leave a Reply to JR Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Close