Virtualbox vs. VMWare

Brad R Monday 29 December 2008 - 16:45:14  

My early tests have already revealed that some of my Windows applications aren't going to run under either Wine or CrossOver. Since I don't want to dual-boot Windows and Linux on the same computer, that means I'm going to have to install some version of Windows to run under Linux. And for me that means using Win4Lin, VirtualBox, or VMware. I may also download a trial version of Parallels Workstation (normally $50).

Win4Lin. For a brief time there was an independent Win4Lin 9x support site. That site has closed, and there is no information about Win4Lin 9x on the current Win4Lin web page. My only choice appears to be to buy the current Win4Lin Pro ($50) and load Windows 2000; I'll save that as a last resort.

VMWare Workstation. VMWare is arguably the outfit that started the x86-virtual-machine business, back in the '90s. (IBM has been doing virtual machines for decades on their mainframes.) I have a copy of VMWare Workstation 5.5 that I acquired a few years ago, and thanks to their generous support policy, I am still able to download the latest version. For testing I am using an older version, 5.5.3. This will run any Windows from 3.1 to XP and 2003; the current version, 6.5 ($189), also handles Vista.

Installation is easy, following the instructions in their PDF manual. As the root user, copy the tar.gz archive to the /tmp directory, extract the archive, and then run the vmware-install.pl script:
cp VMware-workstation-5.5.3-34685.tar.gz /tmp
cd /tmp
tar zxpf VMware-workstation-5.5.3-34685.tar.gz
cd vmware-distrib
./vmware-install.pl

From this point on, simply accept the defaults presented for all the options. As this was an older version of VMWare, it did not have a "vmmon" for my Debian 4.0 Linux. Fortunately I had already installed the gcc compiler and the kernel header files, so the install script was able to build the needed vmmon. (I expect the current version of VMWare has this pre-built.)

To install Windows, launch System > VMWare Workstation, click "New Virtual Machine," and answer the questions presented. By default it will create a "virtual disk" file of a few GB in your home directory, but you can specify that it put this file somewhere else. For most questions you can use the default answers. When the wizard completes, insert the Windows CD-ROM, and click "Power on this virtual machine." The Windows install screen will appear inside the VMWare window; you will need to click inside that screen in order for Windows to see the keyboard and mouse. (And you'll need to press Ctrl-Alt to "release" the keyboard and mouse back to Linux.)

Note: Windows 2000 stalled after the "detecting and installing devices" phase. I needed to reset the virtual CPU (click the "Reset" button in the VMWare control panel). The Windows installation then ran to completion. After rebooting into the guest operating system, press Ctrl-Alt to release the mouse, then click VM > Install VMWare Tools. This modifies Windows for better graphics display, and to let the mouse move out of the window without requiring Ctrl-Alt.

VMWare Tools also allows access to Linux files, if you're running Windows 2000 or later. Under VM > Settings > Options > Shared Folders, you can add any Linux directory as a Windows folder. These appear as network shares in the Windows system -- in Windows Explorer, type the address \\.host\Shared Folders to see them.

VMWare Workstation also allows Windows to access the PC's parallel and serial ports, USB ports, sound, and Ethernet interface. I will be exploring this more in days to come, since I have several Windows applications that need parallel, serial, or USB.

Virtualbox. VirtualBox is available in both open-source and non-open versions. The open-source version involves compiling the source code, and I'm not that ambitious, so I downloaded the binary version under the (no cost) Personal Use and Evaluation License. As it happens, I downloaded version 2.0.6 just days before they released 2.1.0. 2.0.6 will run any Windows from 3.1 to Vista.

Installation was trivial, because they provide a precompiled binary for Debian 4.0 "Etch" (as well as nineteen other Linux distros). I opted to download that package rather than add virtualbox.org to my list of package repositories. The downloaded file installed with two commands (as root):
dpkg -i virtualbox-2.0_2.0.6-39765_Debian_etch_i386.deb
adduser brad vboxusers

The "adduser" command adds my user name to the group that has permission to use virtualbox.

To install Windows, launch System > Sun xVM Virtualbox, click "New", and answer the questions presented. By default it will create a "virtual disk" file of a few GB in your home directory, but it can go somewhere else. For most questions you can use the default answers. When the wizard completes, insert the Windows CD-ROM, and click "Start". You will note that this procedure is nearly identical to that for VMWare. Two differences are that the Windows screen appears in a separate window on the Linux desktop, and you use the right Ctrl key to "release" the keyboard and mouse back to Linux.

This Windows 2000 installation ran smoothly to completion, without stalling. VirtualBox's add-on package for better graphics and mouse support is called the "Guest Additions". Once you boot the guest operating system, in that window click Devices > Install Guest Additions. Then you can move the mouse in and out of the Windows screen and use full color depth.

The Guest Additions also allow access to Linux files. Under Devices > Shared Folders, you can add any Linux directory as a Windows folder. These appear as network shares in the Windows system -- in Windows Explorer, click My Network Places > Entire Network > VirtualBox Shared Folders to see them.

One limitation of VirtualBox for my purposes is that it does not provide any kind of access to the computer's parallel port (LPT1:). For applications requiring that, I'll need to use VMWare. There is support for serial and USB ports, audio, and networking, but I haven't tried those yet.

printer friendly