VirtualBox Guest Additions on Fedora 27/26, CentOS/RHEL 7.4/6.9/5.11 - Comment Page: 4

This is guide, howto install Oracle VirtualBox Guest Additions on Fedora, CentOS and Red Hat (RHEL). This guide should work with Fedora 27/26/25/24/23/22/21/20/19/18/17/16, CentOS 7.4/6.9/5.11, Red Hat (RHEL) 7.4/6.9/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). Install VirtualBox Guest Additions on Fedora, CentOS and Red Hat (RHEL) 1. Change root user su - ## OR ## sudo -i 2. Make sure...

258 comments on “VirtualBox Guest Additions on Fedora 27/26, CentOS/RHEL 7.4/6.9/5.11 - Comment Page: 4

1 2 3 4 5 6 11
  1. JR,

    First off. Thank you for all your tutorials. I wish there was a way to pay your or compensate you, maybe just recommending your site to friends. But, please, accept my many thanks!

    New to linux, have used many of ur tutorials. This one made me stuck.

    My problem is from the beginning.
    When I input: mount -r /dev/cdrom /media/VirtualBoxGuestAdditions
    Sys output: mount: no medium found on /dev/sr0

    From here, I follow instructions to finish w/out visible errors until the end.
    I input: ./
    Sys output: -bash: ./ No such file or directory

    I don’t know what I am doing wrong, all kernel updates say:
    no packages marked for update or already installed and latest version

    please help (at your earliest convenience of course!) :)

    • Hi Zosimo,

      What happens when you click “Install Guest Additions…”?

      Does it mount automatically Virtual Box guest additions on your system?

  2. Hello,
    I have spent the better part of my night trying to install the Virtual Box Guest additions
    My issue was that the install could not find any flies related to kernels under /usr/src/kernels.
    The folder showed as empty.
    The issue was I could not view the files in that folder when logged in to the root account…
    When I logged out and logged back in as “user” then I could view the files and install Virtual Bx guest with no issues…..
    I hope this save someone some time!
    Can any one tell me why I could not view the files in /usr/src/kernels logged in as root?

  3. Here is the output:

    [[email protected] ~]# ls -la /usr/src/kernels
    total 12
    drwxr-xr-x. 3 root root 4096 Nov 21 23:53 .
    drwxr-xr-x. 4 root root 4096 Nov 22 00:45 ..
    drwxr-xr-x. 22 root root 4096 Nov 22 00:45 2.6.32-279.14.1.el6.x86_64
    [[email protected] ~]# rpm -qa kernel\* |sort
    [[email protected] ~]#

    I’m not sure what I did but after getting the tools on CentOS 6.3 the files now show in the /user/src/kernels directory….
    this only happen after logging in as “USER” and installing the tools under that account

    The first time I ran this command “rpm -qa kernel\* |sort” before getting the tolls installed
    it only showed a total of 8 and not 12…

    this is day 3 of me “playing” with Linux so I’m a bit lost in all of this….

    • Your output looks just normal now. It’s hard to say why you get different output now, but normally you should see all files as root user.

  4. Hi,

    This is a nice guide, thank you!
    But I am running into an issue at this step-

    ## Current running kernel on CentOS and Red Hat (RHEL) ##
    KERN_DIR=/usr/src/kernels/`uname -r`-`uname -m`

    I am trying to install Centos 6.3 on a Virtual Box.

    When I run the above command, I get-

    bash: -i686: command not found

    I saw one of the earlier comments and tried the above command with a ‘-i686’ at the end, but that gave the exact same error as well.

    I am stuck, and would really appreciate help!

    Thank you much and regards!

  5. Hi JR,

    Thanks for your response. After my last post, I set KERN_DIR to point to 2.6.32-279.14.1.el6.i686 in usr/src/kernels. But I don’t know if that will cause any trouble. I haven’t used the virtualbox much since then. I am curious why it doesn’t like the path with the ” `uname” and stuff.

    Here are the outputs of the commands you asked me to run-

    [[email protected] sire]# ls -la /usr/src/kernels
    total 16
    drwxr-xr-x. 4 root root 4096 Dec 18 19:39 .
    drwxr-xr-x. 4 root root 4096 Dec 18 20:31 ..
    drwxr-xr-x. 22 root root 4096 Dec 18 20:31 2.6.32-279.14.1.el6.i686
    drwxr-xr-x. 22 root root 4096 Dec 18 16:55 2.6.32-279.el6.i686
    [[email protected] sire]# uname -a
    Linux vmCentos 2.6.32-279.14.1.el6.i686 #1 SMP Tue Nov 6 21:05:14 UTC 2012 i686 i686 i386 GNU/Linux

    Thanks and look forward to hearing from you!

    • Hi again Sumi,

      Yes you can use latest kernel path directly.

      What you get if you try following commands:

      echo /usr/src/kernels/`uname -r`
      echo /usr/src/kernels/`uname -r`-`uname -m`
    • Correction… requires dkms also… Tested on a minimal install. You should update your walkthrough.

      Package requirements also include bzip2 and make

      yum install gcc kernel-devel kernel-headers dkms make bzip2

  6. I am trying to install guest additions on CentoOS 6.3 running in VirtualBox on a Windows 7 64 bit host.

    Followed all the steps but get the following message in vboxadd-install.log after attempting to run sh ./ The only part that failed was the “Building the main Guest Additions module”.

    *** Error: KERN_DIR does not point to a directory.

    I have tried setting KERN_DIR to each of the following without success
    KERN_DIR=/usr/src/kernels/`uname -r`

    The /usr/src/kernels/2.6.32-279.19.1.e16.x86_64 does exist and has stuff in it. There is only the one directory in /usr/src/kernels

    Any suggestions?

  7. Thanks so much. I was totally stuck on how to get a Centos minimal vm to install the guest additions from bash and your instructions saved the day.



1 2 3 4 5 6 11

Leave a Reply

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