VirtualBox: Windows Host, Manjaro Guest

I'll be more enthusiastic about encouraging thinking outside the box when there's evidence of any thinking going on inside it. -- Terry_Pratchett

virtualbox new logo

VirtualBox New Logo

The following is an update to https://www.keypuncher.net/blog/virtualbox-windows-host. We will once again be installing to a Windows host.

Regarding Snapshots

I used to recommend doing snapshots for virtual machines, but now I no longer do. You are much better served by regular backups. What works best for me is doing a once a day or once a week backup (depending on the size of the disk image), but that’s not the only way to do it.

Disadvantages of Virtual Machine Snapshots:

Not a Full Backup: snapshots are not a substitute for full backups. They are designed for short-term use, and relying solely on them for backup can lead to data loss.

Storage Usage: although snapshots are storage-efficient initially, as changes accumulate, they can grow in size and consume significant storage resources. I once had VirtualBox snapshots for a single VM taking up almost 500 GB of space!

Snapshot Chain Complexity and Sprawl: managing multiple snapshots over time can become complex. Long chains of snapshots can make the system unstable and harder to manage. If not carefully managed, snapshots can proliferate, resulting in "snapshot sprawl," which consumes storage and makes it hard to track which snapshot is needed for recovery.

Dependent on Host System: snapshots are tightly coupled to the host system. If there is a failure on the host, restoring from snapshots may not be possible.

That said, there are some advantages:

Advantages of Virtual Machine Snapshots:

Quick Backup and Recovery: snapshots allow for fast creation of a backup image of the virtual machine (VM) at a specific point in time.

Non-Disruptive: creating snapshots typically doesn't interrupt the VM's operation, so it can be done without causing downtime for users or services.

Fast Cloning: a snapshot can be used to quickly create a clone of a VM for testing or production purposes.

But be advised that even in these cases it is wise to quickly migrate to a full backup system!

Download VirtualBox and Set It Up

Navigate to the https://www.virtualbox.org/ web site and download the platform package for Windows hosts. I downloaded VirtualBox-7.1.2.

virtualbox setup wizard

VirtualBox Setup Wizard

Install with the default options.

Click Yes to the Network Interfaces warning.

virtualbox network warning

VirtualBox Network Warning

Proceed using the default settings for custom setup.

Setup

Since I used Ubuntu last time I’d thought I’d give Manjaro https://en.wikipedia.org/wiki/Manjaro a try this time just because I haven’t used it before. Get it from here: https://manjaro.org/products/download/x86. I’m installing the KDE Plasma version because, as of this writing, it is the first option.

In VirtualBox click Tools > New:

virtualbox almost ready

Click Tools > New

Select name and operating system, in our case is Manjaro KDE Plasma, and point it to wherever it was downloaded.  Make sure NOT to select Mandriva Linux because it’s not the same thing.

Manjaro Name, ISO, Tyoe

Manjaro Name, ISO, and Type

Don’t do an unattended install if you can possibly help it! It’s relatively new and in my experience, it always gives folks that try it problems. In my case Ubuntu & RHEL both allowed me to check the “Skip Unattended Installation Box,” but for the Manjaro VM this box is greyed out so as to render it impossible anyway.

This next step is pretty crucial! All the hardware you give to the VM is claimed by the guest OS while it is running. Don’t give it too much or you might suffer for resources in your host OS https://www.techtarget.com/searchitoperations/definition/host-virtual-machine-host-VM.

In the hardware section give it the memory that you need -- I find above 8GB works best. Then select as many CPUs as you will think you need. I choose from 2-4 on my laptop, as follows:

virtualbox sample hardware settings

VirtualBox hardware settings I used

Next specify your hard disk file location and size. Here I specify 20 GB on a VDI:

virtualbox sample hard drive settings

VirtualBox hard disk settings I used

Click Finish to create your virtual machine! Don’t click start just yet, though, we still have a bit of configuration to do. 

Configuration

Manjaro should now show up in the list of VMs:

manjaro now available

VirtualBox now knows about Manjaro

Click on the Manjaro VM you just created then click “Settings” which should bring up the Settings dialog. Under General, click Advanced, and set the shared clipboard to bidirectional:

VirtualBox General Settings

My virtual hardware settings

In Display > Screen > Video Memory I set the guest OS to use half my video memory:

virtualbox sample display settings

My virtual video display settings

Ensure you have NAT https://en.wikipedia.org/wiki/Network_address_translation enabled if you wish to connect to the Internet on this guest. There are other networking options available in VirtualBox https://www.virtualbox.org/manual/ch06.html but I’m only covering NAT:

virtualbox network settings

My virtual network settings

We’ll get to shared folders in a little while after we have set up the VM.

Now you are ready to install the Manjaro OS from the ISO!

Install OS

If VirtualBox is configured on a WiFi network, it’s going to emulate a wired connection, but it will still be wireless in the hardware. This will probably make your download times longer when using the VM.

Click on the Start with the right pointing green arrow as show below:

Manjaro Start Circled

Click Start

You may be asked if you would like your mouse input to be captured. If you choose to do so just remember you can always press <right CTRL> and you will get your mouse back.

Upon boot you will get a menu you may browse. I selected the default “Boot with open source drivers.”

Manjaro boot with open source drivers

Manjaro boot menu

After Manjaro boots, select “Launch Installer” in the resulting menu. Note: I had to resize the window to be able to see the button:

manjaro welcome screen

Manjaro welcome screen

Select language, time zone, keyboard layout, etc.

DO erase disk! Also, I highly recommend creating a swap partition. Up to you whether or not to encrypt:

manjaro disk partitioning

Manjaro partitioning settings I used

Create a name, user name, password. I didn’t log in automatically.

I selected No Office Suite.

Proceed all the way to the installation screen and install Manjaro. Here are my final settings:

My Manjaro final settings

Let it install fully before doing the next step!

Navigate to Devices > Optical Drives > Remove Disk From Virtual Drive. Then click Force Unmount in the resulting dialog. After that power off the VM (shutting down did not work for me on Manjaro -- more on this later).

If you omit this step you will need to eject the installation media from the VirtualBox menu. If you already restarted or shut down, fear not, I did the same thing the first time and will cover how to get around this in the next step.

manjaro devices circled

VirtualBox “Devices” menu location inside the Manjaro guest

If you missed the previous step:

The problem lies in not ejecting the installation media. I forgot to do this on my first go around! To address this power off the virtual machine (if it’s not already off), then go into the Settings screen again, Storage section:

I forgot to remove the virtual installation media my first time through

As you can see, the installation media is still in the virtual drive and the manjaro-kde… ISO wants to start the live installation all over again. Remove it by right-clicking near the icon that looks like a CD then clicking “Remove Attachment” in the dialog that pops up. When it sends the “are you sure?” prompt click “Remove.” Be sure to click the “OK” button in the Settings dialog before you exit. If you click “Cancel” or “Help” the settings will not save.

Installation Note

The shutdown button doesn’t work all the way. You have to force power down after you have pushed the shutdown button. I have to force power off Manjaro every time for some reason. This wasn’t the case on Ubuntu or RHEL.

Post Configuration

Upon opening Manjaro for the first time you will be met with a welcome screen. You will also be invited to install updates, which you should do.

Open a terminal and enter:

sudo pacman -Syu

After updates are installed power off the machine then restart.

Extend screen lock time

Start Menu > Settings > System Settings > Security & Privacy > Screen Locking

Shared Folders

If you want to configure shared folders see my article at: https://www.keypuncher.net/blog/virtualbox-shared-folders.

VirtualBox Guest Additions

Manjaro is the first distro that I have ever used to recognize VirtualBox guest additions, which made me very suspicious.

Because apparently it didn’t because my clipboard doesn’t work between guest and host!

I fiddled around with it for an hour and gave up. I did find this link: Manjaro Linux kernel headers installation - LinuxConfig which was encouraging but I don’t have time to mess around with Arch Linux derivatives because I am not accustomed to them. If anyone figures out how to get guest additions working for Manjaro feel free to add your solution to the comments.

That is all! Short of having not having a bidirectional clipboard working between guest and host, you now have a working Manjaro guest Linux installed in VirtualBox!

Feedback

As always, do make a comment or write me an email if you have something to say about this post!

Credits

Other VirtualBox Images

The right way to update Manjaro: https://itsfoss.com/update-arch-linux/

More on updating Manjaro https://forum.manjaro.org/t/the-correct-way-to-update/28235

Next
Next

Blazing Fast APT Download Speeds