Facebook Twitter Instagram
    TecAdmin
    • Home
    • FeedBack
    • Submit Article
    • About Us
    Facebook Twitter Instagram
    TecAdmin
    You are at:Home»Virtualization»How To Install VirtualBox Guest Additions on Fedora 29-25, CentOS 7/6

    How To Install VirtualBox Guest Additions on Fedora 29-25, CentOS 7/6

    By RahulFebruary 4, 20193 Mins Read

    The VirtualBox Guest Additions provides some device drivers and application for the optimization of performance and usability of Guest operating systems. It is installed inside the Guest operating system. So you need to install on each Virtual Machines running on your system.

    Advertisement

    I recommend to install or upgrade VirtualBox latest version first. This tutorial is to help you with the installation of VirtualBox Guest Additions on Fedora 27/26, CentOS/RHEL 7/6.

    Step 1 – Prerequisites

    First of all, Enable the EPEL release yum repository on your Fedora, CentOS, or RHEL systems. Execute one of the below commands to enable yum repository.

     ### On CentOS/RHEL 7  ### 
    sudo rpm -Uvh http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
    
    ### On CentOS/RHEL 6  ### 
    sudo rpm -Uvh http://epel.mirror.net.in/epel/6/x86_64/epel-release-6-8.noarch.rpm
    

    Step 2 – Upgrade Kernel

    Upgrade your system to use the latest available kernel. To upgrade kernel just execute one of the followings commands on system terminal.

    ### On CentOS/RHEL 7/6  ### 
    sudo yum update kernel*
    
    ### On Fedora 29/28/27/26/25  ### 
    dnf update kernel*
    

    After upgrading the kernel, you must reboot your virtual machine.

    Step 3 – Install Required Packages

    You also need to install some additional packages on your system including kernel-headers and kernel-devel packages.

    ### On CentOS/RHEL 7/6 ###
    yum install make gcc perl dkms bzip2 kernel-headers kernel-devel
    
    ### On Fedora 29/28/27/26/25 ###
    dnf install make gcc  dkms bzip2 perl kernel-headers kernel-devel
    

    Step 4 – Setup Environment Variable

    Set the KERN_DIR environment variable to the kernel source code. In my case, the latest kernel source is available in 2.6.32-504.3.3.el6.x86_64 directory under /usr/src/kernels/ .

    sudo export KERN_DIR=/usr/src/kernels/`uname -r`
    

    Make sure the configured directory exist with proper source code.

    Step 5 – Mount Guest Additions Image

    Mount the guest additions image CDROM on your system in read-only mode. Using below command this will be mounted on /media directory.

    sudo mount -r /dev/cdrom /media
    

    Step 6 – Run Installer

    Your system is ready to run the installer. Execute commands to install the latest VirtualBox guest additions on your system.

    cd /media
    sudo ./VBoxLinuxAdditions.run 
    

    Output

    Verifying archive integrity... All good.
    Uncompressing VirtualBox 5.2.8 Guest Additions for Linux........
    VirtualBox Guest Additions installer
    Removing installed version 5.2.6 of VirtualBox Guest Additions...
    Copying additional installer modules ...
    Installing additional modules ...
    VirtualBox Guest Additions: Building the VirtualBox Guest Additions kernel modules.
    VirtualBox Guest Additions: Look at /var/log/vboxadd-setup.log to find out what went wrong
    VirtualBox Guest Additions: Starting.
    VirtualBox Guest Additions: Building the VirtualBox Guest Additions kernel modules.
    VirtualBox Guest Additions: Look at /var/log/vboxadd-setup.log to find out what went wrong
    

    All done. The latest VirtualBox guest additions package has been installed on your system.

    Guest additions Oracle Oracle VirtualBox VirtualBox
    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email WhatsApp

    Related Posts

    How to Install VirtualBox on macOS

    How to Install VirtualBox on MacOS

    How to Install VirtualBox on Ubuntu 22.04

    How to Install VirtualBox 7.0 on Ubuntu 22.04

    How to Install VirtualBox on Debian 11

    How To Install VirtualBox 7.0 on Debian 11

    View 2 Comments

    2 Comments

    1. JLQ on May 3, 2019 10:58 pm

      It’s not working !
      check the last output in your own tutorial: ” VirtualBox Guest Additions: Look at /var/log/vboxadd-setup.log to find out what went wrong”

      Then, you might realize that libcrypt.so is missing

      Reply
    2. x on April 11, 2019 3:25 pm

      You idiot. “All done” ?? You didn’t even notice the build failures in the output? You’re not even going to mention that it didn’t work?

      Reply

    Leave A Reply Cancel Reply

    Advertisement
    Recent Posts
    • Implementing a Linux Server Security Audit: Best Practices and Tools
    • cp Command in Linux (Copy Files Like a Pro)
    • 15 Practical Examples of dd Command in Linux
    • dd Command in Linux (Syntax, Options and Use Cases)
    • Iptables: Common Firewall Rules and Commands
    Facebook Twitter Instagram Pinterest
    © 2023 Tecadmin.net. All Rights Reserved | Terms  | Privacy Policy

    Type above and press Enter to search. Press Esc to cancel.