{"id":13874,"date":"2022-09-05T23:51:59","date_gmt":"2022-09-05T20:51:59","guid":{"rendered":"https:\/\/kifarunix.com\/?p=13874"},"modified":"2024-03-09T21:34:13","modified_gmt":"2024-03-09T18:34:13","slug":"install-virtualbox-guest-additions-on-oracle-linux-9","status":"publish","type":"post","link":"https:\/\/kifarunix.com\/install-virtualbox-guest-additions-on-oracle-linux-9\/","title":{"rendered":"Install VirtualBox Guest Additions on Oracle Linux 9"},"content":{"rendered":"\n<p>Follow through this tutorial to learn how to install VirtualBox guest additions on Oracle Linux 9. VirtualBox guest additions &#8220;<em>consist of device drivers and system applications that optimize the guest operating system for better performance and usability<\/em>&#8220;.<\/p>\n\n\n\n<p>VirtualBox guest additions can only be installed after the OS has been installed on VirtualBox. In our previous guide, we learnt how to install Oracle Linux 9 on VirtualBox;<\/p>\n\n\n\n<p><a href=\"https:\/\/kifarunix.com\/install-oracle-linux-9-on-virtualbox\/\">Install Oracle Linux 9 on VirtualBox<\/a><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Installing VirtualBox Guest Additions on Oracle Linux<\/h2>\n\n\n\n<p>The Guest Additions offer the following features:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Mouse pointer integration<\/li>\n\n\n\n<li>Shared folders for easy sharing of files between the host and the guest<\/li>\n\n\n\n<li>Ensures better and accelerated video performance.<\/li>\n\n\n\n<li>Seamless windows integration<\/li>\n\n\n\n<li>Generic host\/guest communication channels that enables you to control and manage guest execution.<\/li>\n\n\n\n<li>Provides Host-Guest time synchronization.<\/li>\n\n\n\n<li>Shared clipboard between host and guest vm.<\/li>\n\n\n\n<li>Automated logins.<\/li>\n<\/ul>\n\n\n\n<p>The features are extensively explained on the <a href=\"https:\/\/www.virtualbox.org\/manual\/ch04.html\" target=\"_blank\" rel=\"noopener\">VirtualBox User Manual<\/a>.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Install Kernel Headers on Oracle Linux 9<\/h3>\n\n\n\n<p>To install VirtualBox guest additions, you need to ensure that the Kernel headers are installed. There are other development tools required.<\/p>\n\n\n\n<p>Thus, begin by install EPEL repository on Oracle Linux;<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code>dnf install epel-release -y<\/code><\/pre>\n\n\n\n<p>Next, install the kernel headers and build tools by executing the command below;<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code>dnf install dkms kernel-uek-devel gcc make bzip2 perl elfutils-libelf-devel<\/code><\/pre>\n\n\n\n<p>Next, ensure that the version of&nbsp;<strong>kernel-euk-devel<\/strong>&nbsp;installed does match the version of your running&nbsp;kernel. You can verify by running the commands below.<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td><strong>rpm -q kernel-uek-devel<\/strong><\/td><td><strong>uname -r<\/strong><\/td><\/tr><tr><td>kernel-uek-devel-5.15.0-1.43.4.2.el9uek.x86_64<\/td><td>5.15.0-1.43.4.2.el9uek.x86_64<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>Compare kernel version numbers<\/p>\n\n\n\n<p>If they do not match, as shown in the outputs above, update your kernel by running;<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code>sudo dnf update kernel-uek-* kernel-uek<\/code><\/pre>\n\n\n\n<p>Next, reboot the system and verify the kernel versions again. After the reboot, proceed with installation.<\/p>\n\n\n\n<p>You can install VirtualBox guest additions via the command line or via GUI.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a href=\"#install-guest-additions-iso-cli\">Install VirtualBox guest additions ISO on Oracle Linux 9 via Command Line<\/a><\/li>\n\n\n\n<li><a href=\"#insert-guest-additions-iso\">Install VirtualBox guest additions ISO on Oracle Linux by Inserting from VirtualBox Devices<\/a><\/li>\n<\/ul>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"install-guest-additions-iso-cli\">Install VirtualBox guest additions via CLI<\/h4>\n\n\n\n<p>Confirm VirtualBox version on your host;<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code>VBoxManage --version<\/code><\/pre>\n\n\n\n<p>Sample output;<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code>6.1.38r153438<\/code><\/pre>\n\n\n\n<p>Download&nbsp;<a href=\"https:\/\/download.virtualbox.org\/virtualbox\/\" target=\"_blank\" rel=\"noreferrer noopener\">VirtualBox Guest Additions ISO file<\/a>&nbsp;of the same version as your installed VirtualBox.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code>wget http:\/\/download.virtualbox.org\/virtualbox\/6.1.38\/VBoxGuestAdditions_6.1.38.iso -P \/tmp<\/code><\/pre>\n\n\n\n<p>Mount the guest addition iso under the&nbsp;<code>\/mnt<\/code>&nbsp;directory.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code>sudo mount \/tmp\/VBoxGuestAdditions_6.1.38.iso \/mnt<\/code><\/pre>\n\n\n\n<p>Next, navigate to the mount directory and execute the Linux guest addition installer<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code>cd \/mnt<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-preformatted\"><code>sudo .\/VBoxLinuxAdditions.run<\/code><\/pre>\n\n\n\n<p>Or simply run;<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><code>sudo \/mnt\/VBoxLinuxAdditions.run<\/code><\/pre>\n\n\n\n<p>Sample installation output;<\/p>\n\n\n\n<pre class=\"scroll-box\"><code>\nVerifying archive integrity... All good.\nUncompressing VirtualBox 6.1.38 Guest Additions for Linux........\nVirtualBox Guest Additions installer\nRemoving installed version 6.1.38 of VirtualBox Guest Additions...\nCopying additional installer modules ...\nInstalling additional modules ...\nVirtualBox Guest Additions: Starting.\nVirtualBox Guest Additions: Building the VirtualBox Guest Additions kernel \nmodules.  This may take a while.\nVirtualBox Guest Additions: To build modules for other installed kernels, run\nVirtualBox Guest Additions:   \/sbin\/rcvboxadd quicksetup <version>\nVirtualBox Guest Additions: or\nVirtualBox Guest Additions:   \/sbin\/rcvboxadd quicksetup all\nVirtualBox Guest Additions: Building the modules for kernel \n5.15.0-1.43.4.2.el9uek.x86_64.\nValueError: File context for \/opt\/VBoxGuestAdditions-6.1.38\/other\/mount.vboxsf already defined\nVirtualBox Guest Additions: Running kernel modules will not be replaced until \nthe system is restarted\n<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"insert-guest-additions-iso\">Install VirtualBox guest additions ISO Inserting from Devices Menu<\/h4>\n\n\n\n<p>To begin with, ensure the VM has an empty controller IDE optical drive.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"935\" height=\"551\" src=\"https:\/\/kifarunix.com\/wp-content\/uploads\/2022\/09\/vm-empty-controller-ide.png\" alt=\"Install VirtualBox Guest Additions on Oracle Linux 9\" class=\"wp-image-13883\" title=\"\" srcset=\"https:\/\/kifarunix.com\/wp-content\/uploads\/2022\/09\/vm-empty-controller-ide.png?v=1662410636 935w, https:\/\/kifarunix.com\/wp-content\/uploads\/2022\/09\/vm-empty-controller-ide-768x453.png?v=1662410636 768w\" sizes=\"(max-width: 935px) 100vw, 935px\" \/><\/figure><\/div>\n\n\n<p>Then, open the VM menu and navigate to <strong>Devices &gt; Insert Guest Additions CD Image&#8230;<\/strong><\/p>\n\n\n\n<p>Next, mount the Guest Additions;<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo mount \/dev\/cdrom \/mnt\/<\/code><\/pre>\n\n\n\n<p>Then install VirtualBox guest additions:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo \/mnt\/VBoxLinuxAdditions.run<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">Reboot Oracle Linux 9<\/h4>\n\n\n\n<p>After the installation is done, reboot the system to effect the changes;<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo systemctl reboot -i<\/code><\/pre>\n\n\n\n<p>First thing after the system boots, after you login, it should auto-resize and set screen to full-screen.<\/p>\n\n\n\n<p>If the system do not auto-resize the screen, toggle it on the VM menu by clicking&nbsp;<strong>View<\/strong>&nbsp;&gt;&nbsp;<strong>Auto-resize Guest Display<\/strong>. This can only be done after login.<\/p>\n\n\n\n<div><a href=\"https:\/\/kifarunix.com\/wp-content\/uploads\/2022\/09\/oracle-linux-9-guest-additions.png\" class=\"td-modal-image\"><figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1919\" height=\"1056\" src=\"https:\/\/kifarunix.com\/wp-content\/uploads\/2022\/09\/oracle-linux-9-guest-additions.png\" alt=\"Install VirtualBox Guest Additions on Oracle Linux 9\" class=\"wp-image-13885\" title=\"Install VirtualBox Guest Additions on Oracle Linux 9 1\" srcset=\"https:\/\/kifarunix.com\/wp-content\/uploads\/2022\/09\/oracle-linux-9-guest-additions.png?v=1662410696 1919w, https:\/\/kifarunix.com\/wp-content\/uploads\/2022\/09\/oracle-linux-9-guest-additions-768x423.png?v=1662410696 768w, https:\/\/kifarunix.com\/wp-content\/uploads\/2022\/09\/oracle-linux-9-guest-additions-1536x845.png?v=1662410696 1536w\" sizes=\"(max-width: 1919px) 100vw, 1919px\" \/><\/figure><\/a><\/div>\n\n\n\n<p><a href=\"https:\/\/kifarunix.com\/wp-content\/uploads\/2022\/07\/Oracle-linux-9-virtualbox-11.png\"><\/a>And that is it on how to install VirtualBox guest additions on Oracle Linux 9. You can now enable other features such as shared clipboard, drag and drop between the host and virtual machine.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Other Tutorials<\/h3>\n\n\n\n<p><a href=\"https:\/\/kifarunix.com\/install-virtualbox-guest-additions-on-rocky-linux-9\/\" target=\"_blank\" rel=\"noreferrer noopener\">Install VirtualBox Guest Additions on Rocky Linux 9<\/a><\/p>\n\n\n\n<p><a href=\"https:\/\/kifarunix.com\/install-virtualbox-guest-additions-on-kali-linux-2021-3\/\" target=\"_blank\" rel=\"noreferrer noopener\">Install VirtualBox Guest Additions on Kali Linux 2021.3<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Follow through this tutorial to learn how to install VirtualBox guest additions on Oracle Linux 9. VirtualBox guest additions &#8220;consist of device drivers and system<\/p>\n","protected":false},"author":1,"featured_media":13887,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"rank_math_lock_modified_date":false,"footnotes":""},"categories":[36,121,46],"tags":[5747,5741,5749,1945,5748],"class_list":["post-13874","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-virtualization","category-howtos","category-virtualbox","tag-install-virtualbox-guest-additions-on-oracle-linux-9","tag-oracle-linux-9","tag-oracle-linux-kernel-uek-headers","tag-virtualbox-guest-additions","tag-virtualbox-guest-additions-oracle-linux","generate-columns","tablet-grid-50","mobile-grid-100","grid-parent","grid-50","resize-featured-image"],"_links":{"self":[{"href":"https:\/\/kifarunix.com\/wp-json\/wp\/v2\/posts\/13874"}],"collection":[{"href":"https:\/\/kifarunix.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kifarunix.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kifarunix.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kifarunix.com\/wp-json\/wp\/v2\/comments?post=13874"}],"version-history":[{"count":6,"href":"https:\/\/kifarunix.com\/wp-json\/wp\/v2\/posts\/13874\/revisions"}],"predecessor-version":[{"id":20627,"href":"https:\/\/kifarunix.com\/wp-json\/wp\/v2\/posts\/13874\/revisions\/20627"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/kifarunix.com\/wp-json\/wp\/v2\/media\/13887"}],"wp:attachment":[{"href":"https:\/\/kifarunix.com\/wp-json\/wp\/v2\/media?parent=13874"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kifarunix.com\/wp-json\/wp\/v2\/categories?post=13874"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kifarunix.com\/wp-json\/wp\/v2\/tags?post=13874"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}