I've been looking for a solution to my problem of having to use iTunes to sync my iPhone. I don't want to "jailbreak" it, so I've been pretty much stuck since I'm on Ubuntu and iTunes doesn't work under Wine. I thought about installing Windows in a virtual machine, but Parallels isn't updated for Hardy, VMWare needed me to actually compile it and VirtualBox from the Ubuntu repositories tried to destroy my setup in various ways (replacing my kernel for one, wacking my sound card, etc.), and still didn't work, so I gave up for a bit.
Then I saw a post on Tombuntu about VirtualBox yesterday and learned that there's a different version of VirtualBox in the Ubuntu repositories than the one on Sun's website! I hadn't realized that Sun bought the company that made it.
Sure enough, there's a "Sun xVM VirtualBox" .deb premade for Ubuntu 8.04 (grab it here), and it installs without any major dependencies (just a QT lib), and I just installed a legal version of Windows XP that I own on it. So far so good - it's fast and no problems with networking or the CD. The USB device menu is greyed out right now, but in theory I should be able to get that working as well (which is what I need for the iPhone). If I have any major problems, I'll update this post, but even if I can't get the USB working, this'll be great for the odd Windows app I need to use, or for testing sites in Internet Explorer, etc. without having to have another Windows computer running around the house and using Remote Desktop.
Seriously, I'm pretty amazed. The last time I did virtualization, it was in reverse using VMWare to host Linux on a Windows box and it was a pain in the ass - especially the networking stuff. The fact that it "just worked" so easily in VirtualBox on Linux is nice to see. I wish I had discovered the Sun version first (which is why I'm writing this).
Update: Okay, so the USB needs a little tweaking on Gutsy and Hardy, but no biggie. It's in the FAQ here: "Edit the script `/etc/init.d/mountdevsubfs.sh and activate the four lines around line 40 (Magic to make /proc/bus/usb work)." Then start it and you can add USB devices.
The good news is that Windows saw the iPhone and installed the drivers and even recognizes it as a camera so I can copy off the images. The bad news is that iTunes barfs on it for some unspecified reason. Of course! :-)
Still, I have to say this is working really well. I can't believe how fast the virtual machine starts and works. True, it's a virgin install of XP, which doesn't require much in the way of hardware in the first place, but I'm doing this on a mid-level laptop, so I'm still pretty astounded.
I doubt there's any real fix for the iTunes problem, but I'll update this if I find any solution.