Tuesday, 26 July 2016

Today's Linux Experience: Virtualisation Tools

One of the great things about the major desktop OSs (Windows, OSX and Linux) is that they all have software based hypervisors available to let you run other operating systems as virtual instances in a window on your desktop. When I was getting into PC computing in a big way, the only option we had for running multiple OSs on the x86 platform was by setting up a PC to dual boot. This is a messy system that is hard to maintain and can cause some problems with compatibility of different OSs with a boot manager. At the Polytech there would be dedicated suites for teaching a particular class that had the specific operating systems needed for that class installed on the PCs in that classroom and the class could only be taught in that classroom. But then along came viable virtualisation platforms. The Polytech became a Microsoft school, and I was told they used two VMWare servers to run all of their instructional virtual servers on for all of the different classes. When we went to do a class, we would just grab a pre-configured virtual machine instance and copy it to our local workstation's hard drive and then we could use it in any classroom on the campus or even at home with the free VMWare Player.

The basic types of virtualisation are running in a bare metal hypervisor, like a Hyper-V server, in which everything else on the server consists of instances of different virtual machines, or software based hypervisors which run in a window on a desktop PC. Even the Mac platform can be virtualised these days, although the hypervisor can only run on Mac hardware. Virtualisation is one possible option for getting around the limitations of your favourite software package not being available for the host OS of your computer. On the x86 platform we have more choice than on OSX, so I am not going to look at the latter at all here. The options for Windows have changed from Virtual PC (last produced for Windows 7, which used it to provide the "XP Mode" VM) into a specific Hyper-V platform on higher spec editions of the desktop OS. Unlike earlier instances of VPC, Hyper-V requires specific hardware support, e.g. VT-x or AMD-V implemented in CPU and motherboard. Hyper-V obviously isn't an option for Linux, but here we can draw on two other software products that are also available for Windows. These are VMWare and VirtualBox.  

I have tested both VMWare and VirtualBox on my Linux computers. VMWare is a commercial product that has a free "Player" edition available for various platforms. Due to competition the so-called player has been enhanced to include VM creation capabilities. Installing it onto Linux can be tricky as at times this will require additional modules to be compiled into the kernel, which means you need to have the appropriate minimum version of GCC and the source header files installed as well. The other issue I found was that after using it for a while it would refuse to start up at all. I can't recall the error message but it was not easy to work out a resolution so I gave up on the product at this point. VMWare requires hardware virtualisation support in your computer like Hyper-V Platform and the first edition of Virtual PC for Windows 7 (previous VPC editions did not require this, and the Windows 7 version was later altered to remove this minimum requirement). I noted this when I tested it on one of my AMD E350 systems and unexpectedly got the message that there was no hardware support for virtualisation. At this stage since neither of those systems is now running any Linux edition (both having been pressed into use as backup Windows computers) I have no idea if a Bios upgrade from Gigabyte fixes the problem since the CPU supposedly should supporting AMD-V.

So now I am using VirtualBox due to the tricky to resolve VMWare error messages. Unlike VMWare, VirtualBox is completely free. In fact, it is FOSS, and it can run on many hardware platforms, including OSX, and can also run many guest OSs, also including OSX (on Apple hosts only). Hardware virtualisation support is not always required, however Windows 8 and later and some other OSs as guest mandate it as do 64 bit guests. Multiple monitors are supported. One disappointment has been USB support. I had hoped to have a VM able to run my camera's download software but the VirtualBox manager was unable to detect the camera when plugged in, although I have since learned that there is an extension package that may be needed. So that is where virtualisation has let me down, but maybe this USB thing will work better in future editions of VirtualBox. Other than that I have found it to work very well with a Windows 7 guest and a Lubuntu guest tested out so far. 

Linux users also have additional bare metal hypervisor options available but that is outside the scope of this posting.