I need to run some Windows applications quite often (e.g. Office), but I like to work in a linux environment (openSUSE, usually, but that’s another story). So, I thought the choice was:
- Dual boot
- Keep separate dedicate computers
- Crossover Office, which lets you run some Win apps seamlessly within linux
- vmware, the powerful virtual machine emulator
Choice 1 is incovenient, choices 2-4 expensive (in different degrees). Along comes Sun’s VirtualBox! Completely free and extremely simple to setup.
Some technical comments follow…
OK, I did have some small issues.
- First, the version in the openSUSE 11.1 repositories is an old one. (Remember SUSE is the host system here). It’s better to grab the one in the official site (there’s a specific openSUSE 11.1 rpm file) and install that one (it will need the pam-devel package if it’s not installed).
- Then, folder sharing seems not to work properly. Indeed, it does, but the shared folders are just not visible under Windows XP. I found this in the FAQ section of the official site: Q: I cannot see my newly created shared folder under “My Network Places”. A: Under Windows 2000 they’re visible, but not under Windows XP / Windows Vista. This is because of the standard settings of these two. To get it working the way it was, just do the following steps: 1. Open the Explorer 2. In the menu go to “Tools” and select “Folder Options” 3. Under tab “General” activate “Use Windows classic folders”
- Lastly, I like to run it as a regular user. At first you can, but the second time you run the program you are not allowed to do so, it seems. It just takes a simple chmod a+x /usr/lib/virtualbox/VirtualBox as root to fix the problem.
Update: I have now two case studies in which I have used VirtualBox.
- The first is the above one: a linux system in which windows is occasionally employed. Nice results in general; access to filesystem seems to be slow when the windows guest is accessing the shared folders, but not a great deal. I can also print through the host linux OS; a network printer should be added in Windows XP, with the address http://10.0.2.2:631/printers/_name_of_printer (the later is simply “hp” in my system) – see this post.
- The second is the opposite situation: a laptop in which, for certain reasons, windows is generally used, but on which some linux features may be needed from time to time. Disk space is scarce, so the avoidance of partitioning is a big plus. A thin openSUSE guest (with the nice Xfce window system) works great, and folder sharing is very easy.
Another update: I have now another case study:
This has been SUSE 11.1 (I know, kind of old, but that’s the DVD I had around) under Windows 7 in my new ASUS laptop. As I said, everything works fine, but:
- Do not download the Guest Additions ISO image, it’s already included in the .exe (I stress: windows is now the host OS).
- The internet connection was a bit shaky, which can make updating linux quite a pain. See a solution here.
- File sharing works extremely well.
- First, install the Guest Additions, just mounting the ISO image. It has a menu to do it, no need to use Daemon tools or anything.
- Then, run the appropriate .sh script. The 64b version is the one with amd64 in the filename (even for an intel CPU). You will need to have installed kernel-sources, kernel-syms, and kernel-headers.
- Then, assign shared folders, from the manual: select “Shared folders” from the “Devices” menu, or click on the folder icon on the status bar in the bottom right corner of the virtual machine window.
- Whenever you need, run “mount -t vboxsf [-o OPTIONS] sharename mountpoint”. I didn’t need any options. An ordinary user can run it (no need to login as root, or use sudo). In sharename, use whatever label you used in the previous step.
- The nice thing: you can create and edit files from within linux that are instantly visible under windows. And vice versa. This feels magic! I am brazing myself for what the future may bring: potential file corruption, encoding issues…