Last Updated on 10 months by Sachin G
VirtualBox is an easy-to-use application that lets you run different operating systems on one machine. If you’re using Ubuntu 22 and want to create a machine with virtualization, these steps will help you install VirtualBox easily. It opens up a world of options, letting you run different operating systems smoothly.
Key Features of VirtualBox:
- It supports Windows, macOS, Linux, and more, providing flexibility for users with different operating systems.
- It is freely available for personal and professional use, and its source code is also accessible.
- You can take snapshots of virtual machines at different states, allowing easy rollback to a previous state.
- Resources like CPU and memory can be dynamically allocated.
- We can also configure various network modes, including NAT, Bridged, and Host-Only, to suit different networking requirements.
- We can also choose between dynamically allocated and fixed-size virtual hard disks, providing flexibility in storage management.
- It can run without showing a desktop interface, which is useful for servers.
- If you have more than one monitor, VirtualBox can use them all at the same time.
- it makes it easy to share files between your computer and the virtual one.
- Getting VirtualBox is easy, and it comes with a simple interface to manage your virtual machines.
- It has a lot of helpful information and a community where people share advice and solutions.
Step 1: Update Your Operating System
Before starting the installation, You should ensure your system is up to date. Open the Terminal and run the following commands:
sudo apt update | sudo apt upgrade
Step 2: Import-Package Repositories & keys
Download & Registering the Oracle provided the public key for verifying to authenticate. The below command is doing both downloading and registering.
sudo wget -O- https://www.virtualbox.org/download/oracle_vbox_2016.asc | sudo gpg --yes --output /usr/share/keyrings/oracle-virtualbox-2016.gpg --dearmor
The below command will Add the oracle repository. This command adds Oracle’s VirtualBox repository to your system’s list of repositories.
echo "deb [arch=amd64] http://download.virtualbox.org/virtualbox/debian $(lsb_release -sc) contrib" | sudo tee /etc/apt/sources.list.d/virtualbox.list
Step 3: Install & Launch VirtualBox
Install and update before installation using the following command
sudo apt-get update
sudo apt-get install virtualbox-7.0
Step 4 : Add Your User to the “vboxusers” Group
Ensure smooth access to USB devices and other features by adding your user to the “vboxusers” group:
sudo usermod -aG vboxusers $USER
With the installation complete, you can now launch from the application menu or use the Terminal:
virtualbox
VirtualBox is ready for use! Create new virtual machines, and install different operating systems. Congratulations! You’ve successfully installed VirtualBox on Ubuntu 22.
I am a professional freelance contributor and the founder of Tech Transit. I hold certifications in Linux, Ansible, and OpenShift from Red Hat, as well as CPanel and ITIL certifications. With a passion for education, culture, and community, I love writing and sharing knowledge. Since 2009, I’ve been actively using, setting up, supporting, and maintaining Linux systems. Linux truly rocks!