Making the choice to move from windows to Linux is a big commitment, so it makes sense to try it out before you pull the trigger. It’s easy to test a Linux ISO from the comfort of your desktop with virtualization software such as Virtual Box or VMware.
In this article, I’ll guide you through the step-by-step process of installing Linux on VirtualBox
What Is VirtualBox
VirtualBox is an open source multiplatform hypervisor for x86 virtualization, and runs on Windows, macOS, and Linux. This allows you to run multiple virtual PCs without leaving your own OS.
Each VirtualBox machine is treated as a complete PC in it’s own right, with its own RAM, processor threads, and virtual hard disk. This means you can try out as many Linux distros as you want, and if you don’t like them, just delete the VM, and start again!
Before we start, you’ll need a few things:
- A computer with Windows or Mac operating system
- CPU with at least four cores
- At least 4 GB of RAM (8 GB or more recommended)
- VirtualBox software
- A Linux distribution ISO file
Download and Install VirtualBox
To get started, visit the VirtualBox download page, and click on “Windows hosts”. When prompted, save the .exe file to your desktop. VirtualBox is updated regularly, so the exact filename will vary.
Double click on the VirtualBox app to start installation, and click “Yes” when asked if you want to allow the app to make changes to your device.
The installation wizard will ask you where you want to install VirtualBox. Leave the location as default, and click “Next”.
You may receive a Network Interface warning, stating that you’ll be temporarily disconnected, but this is safe to ignore unless you’re downloading a large file.
Click “Next”, then “Yes” when asked if you want to install dependencies.
Finally, you can click on the “Install” button, and when the installation is complete, hit “Finish”, and VirtualBox will start automatically.
Install VirtualBox Extension Pack
If you want support for VirtualBox RDP and disk encryption, you should also install the VirtualBox extension pack.
Download Linux ISO
The next step is to download a Linux distribution ISO file.
For the purpose of this guide, I’m using Linux Mint Cinnamon edition, but these instructions will work for most modern Linux distros.
Visit the Linux Mint download page, and choose select which version you want. Click on download, and save the ISO file to your desktop.
Create a New Virtual Machine
The VirtualBox interface is divided into two sections. The section on the left shows the virtual machines available to use, while the right side shows details of the virtual machine you have selected. A panel in the top right will show a thumbnail view of any running VMs.
As you’ve just installed VirtualBox, Both sides of the screen will be empty. Click on “New” to create a new Virtual Machine.
In the popup, you’ll need to provide a name for your VM. Choose something memorable, which makes it clear which OS will be installed. I’m installing Linux Mint Cinnamon edition, and named my machine “LinuxMint”.
If VirtualBox recognizes the name, it will automatically prefill the “type” and “version” drop-downs.
Tick the check box to skip the unattended installation, then click “Next”.
Allocate Memory & Processors
Your Virtual machine needs virtual memory and a virtual processor, and if you want decent performance from your virtual Linux install, give it as many resources as you can spare without starving your host machine.
The RAM and processor sliders are both color coded as green and red to give you an indication of how much you can spare. Click “Next” when you’re satisfied.
Create a Virtual Hard Disk
You will also need a virtual hard drive. Check your distro’s minimum requirements, and add space according to how much software you think you’ll install.
VirtualBox will expand your virtual hard drive into ‘real’ disk space as it fills up. If you’d prefer to have it occupy its full size on your storage device from the start, check the “Pre-allocate full size” box. Click “Next” then “Finish”.
Configure Virtual Machine Settings
While Linux should run well on your VirtualBox virtual machine as you’ve configured it, there’s one more thing to do.
Click on settings to open up your VM’s settings, then select “Display”. Allocate as much video memory as you can. Check Enable 3D Acceleration, then hit “OK”.
Install Linux on VirtualBox!
With the preparation out of the way, it’s finally time to install Linux.
Press the green “Start” arrow, and a new window will open. This is your virtual display, so think of it as a separate monitor. The rest of the install process will take place in here.
The first thing you’ll see is the GRUB (GRand Unified Bootloader) boot menu. Use the arrow keys on your keyboard to select top item on the list, which should be to start your distro.
Within seconds, you’ll be on the desktop. Here you can play around with the system, test out apps, and connect to Wi-Fi. You can even install software, but any changes you make won’t be saved.
There will be an icon prominently displayed on the desktop, with a label such as “Install Linux Mint“. Double click it to start the installation wizard.
The decision to install Linux is all about choice, and the first choice you have to make is your system language. Select it from the list, then press “continue”.
You’ll then choose your keyboard layout, and decide whether you want to install multimedia codecs (you probably do).
Normally when installing Linux, you’ll need to consider disk partitioning and space allocation. As you’re installing on a virtual disk, created specifically for Linux, you should choose “Erase disk and install”, when asked to choose an installation type.
Click “Install Now”, and the wizard will ask you to confirm that you want to write changes to the disk. Press “Continue”, then pinpoint your location on the map.
After this, you’ll choose how to identify both yourself and your VM. Choose a suitable username, and a strong, easy to remember password. You can also change the computer name.
Finally, choose whether to log in automatically, in which case your VM will boot straight to desktop without requiring you to log in, and if you want to encrypt your home directory. This will prevent other users on the same system from snooping on your personal files, but on a virtual machine, it’s probably unnecessary.
When you press “Continue”, Installation will proceed without any further intervention.
Go and make a cup of tea, while Linux is installed on your VM, and watch the slideshow to get familiar with promoted features. When it’s done, you can choose to continue in the live environment or restart and boot to your shiny new Linux desktop!
It’s easy to install Linux in VirtualBox
Installing Linux to a virtual machine rather than bare metal is a great idea if you’re not sure that you want to commit to a particular distro. VirtualBox makes it simple to try as many distros as you want, and if you don’t like one, just delete the VM and try another. Alternatively, you can make copies of your virtual machine to experiment with configuration changes without the risk of ruining your daily driver.