Skip to main content

Virtualization: VirtualBox

I've been using VMware Fusion, but I decided to give VirtualBox a try. It's from Sun. To summarize:
  • It seems faster than VMware Fusion
  • It's free and mostly open source
  • It's just a bit rougher around the edges
What do I mean it's mostly open source? There are two versions. According to their docs:
The VirtualBox Open Source Edition (OSE) is the one that has been released under the GPL and comes with complete source code. It is functionally equivalent to the full VirtualBox package, except for a few features that primarily target enterprise customers. This gives us a chance to generate revenue to fund further development of VirtualBox.

Please note that the Open Source Edition does not include an installer or setup utilities, as it is mainly aimed at developers and Linux distributors
What this means in practice is that it's not easy to use the open source version since there are no precompiled binaries and no installer. Hence, you're stuck with the free, but not open source version. The two things that I actually care about that are missing from the open source version are USB support and a gigabit ethernet controller. Oh well. That's still better than what I had to pay for VMware Fusion.

As for speed, I haven't actually timed it, but the BIOS stage of booting is crazy fast, and installing Ubuntu didn't seem to take forever like it did under VMware Fusion. Of course, this could be a figment of my imagination. I can't remember if I had the same amount of RAM when I installed Ubuntu under VMware Fusion either, so take my comments with a grain of salt. I will say that sound seems smoother.

Speaking of sound, by default it's turned off. That was easy to fix.

By default it uses NAT, and the host computer cannot connect to the guest computer. Since I like to login over ssh, that was a no go. I figured out how to switch to "Host Interface Networking", and I was happy again. In general, this is one area where VMware Fusion seemed to just work.

Just like VMware Fusion, VirtualBox has custom kernel mods for Linux. Installing them was easy. Once I did, the mouse was perfectly integrated between the host and guest computers. Furthermore, full screen mode now uses the same resolution as my Mac. Sweet!

To be fair, VMware Fusion does the same thing. Of course, this only works for Linux and Windows. There are no kernel mods available (that I know of) for other operating systems like FreeBSD.

One more feature that I haven't bothered trying out is:
Shared folders. Like many other virtualization solutions, for easy data exchange between hosts and guests, VirtualBox allows for declaring certain host directories as "shared folders", which can then be accessed from within virtual machines.
Anyway, it's good stuff. I'm guessing that VMware Fusion is probably better if you need to run a Windows client (because of all the "Fusion" functionality), but if you just need to run a Linux client, VirtualBox is free and good.


I use VirtualBox by preference.

As to networking there are three modes. NAT, Private, Host. The reason is simple -- ability to support network testing. For example I can set up a private only with 4 guests. One of the guests I can utilize 2 Eth's. One private, one Host. That way I can test gateway software. Or I can turn off the second NIC and run a private test LAN seperate from the rest of the net.

Shared folders work like a charm.

Neat trick department: Want client guests but don't want to eat up disk space with VDI's? Configure guest space with no VDI. VB accepts that config. Now install a live cd or one of the many 'in ram' Linuxes (eg Siltaz, Puppy). They run perfectly. Just remember to save their state before you close them down or you will have to go through the install again.
Anonymous said…
I ocasionally need to run windows. I guess for Mac/Win OSE is a pain unless you find a precompiled version. I'm using it on Gentoo and finding it really straightforward.
When VMware no longer booted my windows guest, it made it hard to do the vmware->VB migration (since it requires booting/tweaking under vmware), so I just reinstalled.
The open source aspect is appealing for freetards like me (I guess gentoo kinda gets around the need for compilation, but I know that ubuntu has OSE in it's repos too, as I would image most distros do)
Anonymous said…
I use Virtualbox now, too. One of the good things about VirtualBox is, it supports more recent linux kernel versions, where vmware needs quite some patching to work
Unknown said…
I've been using VirtualBox on my MacBook for a couple of months. It was my workaround to getting GnuCash running on the Mac. After a few hours of chasing failures in the GnuCash build under MacPorts, I grabbed VirtualBox, installed Ubuntu 8.10 as a guest OS while I ate breakfast one morning, and had GnuCash running under Ubuntu not long afterward.

Shared folders work fine to give me access to my GnuCash data stored on my server - just have to remember to mount the directory from the server before I try to mount it in the vbox/ubuntu. Interestingly, the mount on the Ubuntu side sometimes (but not always) survives a Leopard-side unmount/re-mount of the server directory!

One limitation I have found is that OpenBSD does not play well in VirtualBox, despite it being listed as being supported. I've been able to do installs of 4.3 and 4.4 (others report failures during installation) but the resulting guest systems segfault far to often to be useful. Apparently this is a known issue that Sun has declared they have no intention of fixing because the user demand for OpenBSD is too small.
jjinux said…
VirtualBox crashed on me while I was trying to setup USB.

Firefox on my guest machine crashed one me while I had a USB stick plugged in and configured under VirtualBox.
jjinux said…
I started up Ubuntu under VirtualBox and then switched to another virtual desktop on my Mac. When Ubuntu was finished loading, I switched back to log in. The keyboard wouldn't work. I had to reboot Ubuntu and make sure my focus was on it the entire time in order for the keyboard to work. Weird.

Popular posts from this blog

Drawing Sierpinski's Triangle in Minecraft Using Python

In his keynote at PyCon, Eben Upton, the Executive Director of the Rasberry Pi Foundation, mentioned that not only has Minecraft been ported to the Rasberry Pi, but you can even control it with Python. Since four of my kids are avid Minecraft fans, I figured this might be a good time to teach them to program using Python. So I started yesterday with the goal of programming something cool for Minecraft and then showing it off at the San Francisco Python Meetup in the evening.

The first problem that I faced was that I didn't have a Rasberry Pi. You can't hack Minecraft by just installing the Minecraft client. Speaking of which, I didn't have the Minecraft client installed either ;) My kids always play it on their Nexus 7s. I found an open source Minecraft server called Bukkit that "provides the means to extend the popular Minecraft multiplayer server." Then I found a plugin called RaspberryJuice that implements a subset of the Minecraft Pi modding API for Bukkit s…

Apple: iPad and Emacs

Someone asked my boss's buddy Art Medlar if he was going to buy an iPad. He said, "I figure as soon as it runs Emacs, that will be the sign to buy." I think he was just trying to be funny, but his statement is actually fairly profound.

It's well known that submitting iPhone and iPad applications for sale on Apple's store is a huge pain--even if they're free and open source. Apple is acting as a gatekeeper for what is and isn't allowed on your device. I heard that Apple would never allow a scripting language to be installed on your iPad because it would allow end users to run code that they hadn't verified. (I don't have a reference for this, but if you do, please post it below.) Emacs is mostly written in Emacs Lisp. Per Apple's policy, I don't think it'll ever be possible to run Emacs on the iPad.

Emacs was written by Richard Stallman, and it practically defines the Free Software movement (in a manner of speaking at least). Stal…

ERNOS: Erlang Networked Operating System

I've been reading Dreaming in Code lately, and I really like it. If you're not a dreamer, you may safely skip the rest of this post ;)

In Chapter 10, "Engineers and Artists", Alan Kay, John Backus, and Jaron Lanier really got me thinking. I've also been thinking a lot about Minix 3, Erlang, and the original Lisp machine. The ideas are beginning to synthesize into something cohesive--more than just the sum of their parts.

Now, I'm sure that many of these ideas have already been envisioned within, LLVM, Microsoft's Singularity project, or in some other place that I haven't managed to discover or fully read, but I'm going to blog them anyway.

Rather than wax philosophical, let me just dump out some ideas:Start with Minix 3. It's a new microkernel, and it's meant for real use, unlike the original Minix. "This new OS is extremely small, with the part that runs in kernel mode under 4000 lines of executable code." I bet it&…