Why I switched from VirtualBox to WSL 2
Introduction
I was first introduced to VirtualBox my junior year of college when I wanted to better learn Linux. I wasn’t ready to go “full Linux” and install it as my main OS like some of my techie friends. All I was looking for was a taste. VirtualBox offered that taste, and for a while, it was sweet. I have installed multiple Linux distributions. However, recently I started experiencing annoying problems with VirtualBox. Now, I’m ready to explore other options.
An option I am currently enjoying is Windows Subsytem for Linux version 2 (WSL 2). It is a new way to experience Linux on Windows 10. Nice replacement for Cygwin!
This article is a mini rant on my recent frustrations with VirtualBox.
Why do I want a Linux VM in the first place?
Simple programming environment
My programming projects are minuscule compared to production-level code made by a company. For that reason I prefer to use a text editor and compiler instead of a massive IDE. Programming in Vim and using a Linux terminal to compile my code is all I need.
CTF and wargame challenges
Many of the CTF and war game challenges I play are Linux based. Especially the binary exploitation and reverse engineering categories. These would be difficult (if not impossible) to solve in plain windows 10.
Not ready to dual boot
I’m simply not ready to dual boot into a Linux partition. I’m fine with using Windows as my main OS for web browsing, emails, and work. I only want Linux for programming and CTFs.
To learn something new
Learning something new, whether its a programming language, framework, or operating system, is just a lot of fun!
Now onto the main purpose of this article:
Why I’m leaving VirtualBox
- VirtualBox has been slowwww to load
- Guest Additions does not work consistently. It’s not uncommon for the display screen to be half sized. I’ll fix it momentarily with the help of a StackOverflow post, only for the problem to return later.
- My laptop would take forever to wake up from sleep mode if I was running a guest OS. A few times my laptop would not wake up at all, and need to be restarted.
- Splitting system resources, such as RAM or cpu cores with the host OS handicaps both the host and guest.
What I like about WSL 2 (so far)
- It loads much much faster. Only a few seconds!
- As far as I can tell, I have full access to all of my system resources. Meaning no more handicaps.
- Installing different distributions is quick and painless. They are simply downloaded from the Microsoft store. No longer do I need to download an iso file and configure a guest OS.
Conclusion
If you’ve made it this far, thanks for sitting through my mini rant. It feels good to vent. I still like VirtualBox, however it hasn’t been working well with my current laptop. I’m sure it will run smoothly on my gaming desktop.