Easy way to Install VirtualBox on Oracle Linux

0
10

Are you running Oracle Linux desktop and want to do some Virtualizations? Thus, follow through this guide to learn how to install VirtualBox on Oracle Linux. In this tutorial, we will be using Oracle Linux 9.

How To Download & Install Oracl...
How To Download & Install Oracle 11g on Windows 10

Easy way Install VirtualBox on Oracle Linux

There are two ways in which you can easily install VirtualBox on Oracle Linux.

  1. Manually using Oracle Linux RPM Binary Package
  2. Automatically via Oracle Developer YUM repositories

Install Linux Kernel Headers on Oracle Linux

Before you can proceed, ensure that the kernel headers matching the version of the running kernel is installed;

sudo dnf install kernel-uek-devel

Confirm that the version numbers shown by these commands are similar;

uname -r
5.15.0-1.43.4.2.el9uek.x86_64
rpm -q kernel-uek-devel
kernel-uek-devel-5.15.0-1.43.4.2.el9uek.x86_64

If not, then update the kernel headers;

sudo dnf update kernel-uek-*

Install VirtualBox on Oracle Linux using RPM Binary Package

Download RPM binary package for your specific Oracle Linux release from VirtualBox downloads page.

wget https://download.virtualbox.org/virtualbox/6.1.38/VirtualBox-6.1-6.1.38_153438_el9-1.x86_64.rpm

Once the download is complete, run the installation.

sudo dnf localinstall VirtualBox-6.1-6.1.38_153438_el9-1.x86_64.rpm

You can also get the download link and do the installation directly;

sudo dnf install https://download.virtualbox.org/virtualbox/6.1.38/VirtualBox-6.1-6.1.38_153438_el9-1.x86_64.rpm
============================================================================================================================================================================
 Package                                   Architecture                 Version                                                   Repository                           Size
============================================================================================================================================================================
Installing:
 VirtualBox-6.1                            x86_64                       6.1.38_153438_el9-1                                       @commandline                         91 M
Installing dependencies:
 SDL2                                      x86_64                       2.0.20-2.el9                                              ol9_appstream                       611 k
 libdecor                                  x86_64                       0.1.0-3.el9                                               ol9_appstream                        45 k
 pcre2-utf16                               x86_64                       10.37-3.el9.1                                             ol9_appstream                       211 k
 qt5-qtbase                                x86_64                       5.15.2-29.el9                                             ol9_appstream                       3.7 M
 qt5-qtbase-common                         noarch                       5.15.2-29.el9                                             ol9_appstream                        12 k
 qt5-qtbase-gui                            x86_64                       5.15.2-29.el9                                             ol9_appstream                       6.4 M
 qt5-qtx11extras                           x86_64                       5.15.2-6.el9                                              ol9_appstream                        41 k
 sdl12-compat                              x86_64                       0.0.1~git.20211125.4e4527a-4.el9                          ol9_appstream                        88 k
 xcb-util-image                            x86_64                       0.4.0-19.el9                                              ol9_appstream                        20 k
 xcb-util-keysyms                          x86_64                       0.4.0-17.el9                                              ol9_appstream                        15 k
 xcb-util-renderutil                       x86_64                       0.3.9-20.el9                                              ol9_appstream                        18 k
 xcb-util-wm                               x86_64                       0.4.1-22.el9                                              ol9_appstream                        32 k

Transaction Summary
============================================================================================================================================================================
Install  13 Packages

Total size: 102 M
Total download size: 11 M
Installed size: 240 M
Is this ok [y/N]: y

Install VirtualBox on Oracle Linux via YUM Repositories

If you like, you can install VirtualBox on Oracle Linux via YUM Repositories;

To use this method, install Oracle Linux Developer repositories;

sudo tee /etc/yum.repos.d/ol9-epel.repo << 'EOL'
[ol9_developer]
name= Oracle Linux $releasever_$basearch
baseurl=https://yum.oracle.com/repo/OracleLinux/OL9/developer/$basearch/
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
gpgcheck=1
enabled=1
EOL

Next, install VirtualBox on Oracle Linux;

sudo dnf install VirtualBox-6*

Add VirtualBox users to VBOXUSERS group

VM users must be member of vboxusers group.

You can add users to group as follows;

sudo usermod -aG vboxusers USERNAME

E.g, to add a user, kifarunix, to the group.

sudo usermod -aG vboxusers kifarunix

Launching VirtualBox on Oracle Linux

You can now launch and use VirtualBox on Oracle Linux.

Easy way to Install VirtualBox on Oracle Linux
Easy way to Install VirtualBox on Oracle Linux

That concludes our guide on an easy way to install VirtualBox on Oracle Linux.

Other Tutorials

Install VirtualBox Guest Additions on Oracle Linux 9

Install Oracle Linux 9 on VirtualBox

LEAVE A REPLY

Please enter your comment!
Please enter your name here