I’ve been a bit quiet here recently because I’ve mainly been working with my business laptop currently running Windows 7. You can see more about this on my other blog – Much Ado about IT. However, the power supply on that died recently so I’m back to my trusty desktop which runs OpenSUSE 11.0 24×7. I managed to get hold of an upgraded CPU for this a while back but I’ve not really had an incentive to upgrade till now.
Yep, I keep being amazed by the quality of VirtualBox which is now owned by Sun. I need to set up a virtual machine to test and demo Sun’s Identity Management (IdM) suite and it needs to be usable with VMware too. So I headed over to the VMware Appliances web site and downloaded a pre-canned Debian 5 server. This is recognised fine by VirtualBox! I gave the VM a Host Networked connection to the network and with no further configuration, fired up the VM.
Great news! The latest versions of VirtualBox have sorted out the issues of host networking. So all of the messing around that you used to have to do, especially under Linux, is now over. So ignore the previous post, it is no longer required.
I prefer to use VirtualBox rather than VMware as it seems to be rather faster and less resource hungry than VMware Server (the only free version of VMware with a GUI). Also VirtualBox seems to have better Linux host support (sound, etc.). However, there is one thing that VMware is better at – setting up the guest network on the same network as the host. Under VirtualBox this is called “Host Interface Networking” and, with a Linux host anyway, is a right royal pain to set up.
By default, OpenSUSE 10 & 11 come preconfigured WITHOUT usbfs active. Unlike Ubuntu, everything is ready to go but the fstab setting is “noauto” so it doesn’t seem to get loaded even when VirtualBox wants it. The fix for this is simple and is listed in the VirtualBox User FAQ. In “/etc/fstab” change the line for usbfs to: usbfs /proc/bus/usb usbfs auto,busgid=XXX,busmode=0775,devgid=XXX,devmode=0664 0 0 Where XXX is the group id of the vboxusers group which can be discovered in YAST or from the command line: grep vboxusers /etc/group That’s it, no other changes should be needed.
When you want to access the hosts file system from a guest OS in VirtualBox, you need to mount the virtual share. However, the default mount: sudo mount -t vboxsf <VBox-share-name> <mount-location> Will mean that only root can write to the shared folders. You need to tweak things to get a system that an ordinary user can write to. Here is the script I use: #!/bin/bash echo " " echo "Script to mount the host disk under VirtualBox" echo " " USR=`whoami` SHARE='Host-Root' MNT="/home/$USR/VBoxHostRoot" echo " Mounting $SHAREto $MNT.
I’ve been thinking ahead to a change of job recently. Knowing that I’ll be getting a new Windows based laptop and needing to have development capabilities and having developed a taste for Linux 😉 I’ve used my favourite VM tool VirtualBox (now owned by Sun) to create a sparlkly new OpenSUSE 11.0 virtual machine complete with Apache, MySQL, PHP, etc. as well as office tools such as Open Office, mind/concept-mapping and diagraming applications.