VirtualBox is a free and open-source tool by Oracle to run virtual machines on a system. It is available for different operating systems including Windows, macOS, and Linux.
By creating virtual machines on a system you can install multiple operating systems within your host OS. For example, you can install different distributions of Linux inside Windows.
In this article, I will discuss how to install VirtualBox in Fedora Workstation.
System requirements
To install and use VirtualBox on a Fedora system you should have a computer with a minimum configuration as given below.
- A recent 64-bit version of Fedora Workstation
- 4 GB RAM
- 30 GB of internal storage
- x86_64 CPU, with Intel VT-x/AMD-V/SVM
Note:- At the time of writing this tutorial Fedora 34 Workstation is the latest version of Fedora Linux
How to install VirtualBox in Fedora
To install VirtualBox in Fedora first you need to download the virtualbox.repo
and add it to /etc/yum.repos.d
configuration file.
Use the following command to download and add the repository to the configuration file –
sudo wget http://download.virtualbox.org/virtualbox/rpm/fedora/virtualbox.repo -P /etc/yum.repos.d/
Next, import the public key by using –
rpm --import https://www.virtualbox.org/download/oracle_vbox.asc
Run the update command to refresh the package repository on your system –
sudo dnf update -y
Installing development tools and dependencies
You need to install the development tools and dependencies that are required for building the VirtualBox Linux kernel module on Fedora. Run the given command to install the development tools –
sudo dnf install @development-tools
Use the following command to install the required dependency packages –
sudo dnf install kernel-devel kernel-headers dkms qt5-qtx11extras elfutils-libelf-devel zlib-devel
When it asks for your confirmation press y and then enter.
Installing VirtualBox in Fedora
After installing the development tools and required dependency use the given command to install the latest version of VirtualBox.
sudo dnf install VirtualBox-6.1
Press y and then enter if it asks for your confirmation.
This will start the downloading and installation process on your system.
Start the VirtualBox in Fedora
Once the installation of VirtualBox is completed you can launch it from the activities dashboard as you can see in the image below.
OR use the following command if you want to launch it from your terminal –
virtualbox
This will launch the Oracle VM VirtualBox on your Fedora system.
Now you can start creating or importing virtual machines in VirtualBox on a Fedora system.
You can follow how to install VirtualBox in Ubuntu if you want to install it on a Ubuntu system.
Conclusion
I hope this guide is helpful for you. If you have a query then write us in the comments below.