As you have probably seen on every blog under the sun, Hyper-V has released.
Rather than rehash the announcement, I thought I would try something fun. How hard is it to get various Linux distributions up and running in Hyper-V?
The official list of supported operating systems on Hyper-V is available here: http://www.microsoft.com/windowsserver2008/en/us/hyperv-supported-guest-os.aspx. While there are a ton of supported Operating Systems, you will notice only one supported Linux distro:
Linux Distributions (VMs configured with 1 virtual processor only)
SUSE Linux Enterprise Server 10 with Service Pack 2 x86 Edition
SUSE Linux Enterprise Server 10 with Service Pack 2 x64 Edition
SUSE Linux Enterprise Server 10 with Service Pack 1 x86 Edition
SUSE Linux Enterprise Server 10 with Service Pack 1 x64 Edition
Before we go any further, I want to clarify "supported" (and this is my own paraphrasing, not the Official Microsoft Support Policy). Supported means that we have thoroughly tested a specific configuration. If you have a problem, you can call up Microsoft Support, and we will troubleshoot and resolve the problem, and release a fix if necessary. If the problem is with somewhere in SUSE, we can work with the fine folks at Novell to have a fix released on their end. In other words, if you are running SUSE Linux Enterprise Server 10 on top of Hyper-V and encounter a problem, between Microsoft and Novell, we will support you. If you are running your company on Hyper-V virtualized instances of BeOS or Ubuntu… you do so at your own risk. Is it because we hate BeOS or Ubuntu? Heck No! It’s just that we can’t do a whole lot to fix a problem when a linux kernel update breaks compatibility. Can you imagine the slashdot story if we released updates to the Linux kernel? Good grief!
Just because something isn’t "supported", however, doesn’t mean that it won’t work.
If you are running servers in a production environment, you want to be in a supported configuration (see above). If you are a an IT-Pro geek that just likes playing with things to see how they work, then you can throw caution to the wind and try things out that haven’t been tested :) With that… let’s load a few distros up on Hyper-V!
(by the way, Hyper-V has a really cool "Capture screen" option that is awesome for taking screenshots
On Virtual PC 2007, OpenSuse 10.2 installed like a champ. OpenSUSE 11 was somewhat touch-and-go. On Hyper-V, OpenSUSE 11 installs and runs like a champ. The following screenshots are all from the installation:
The only thing that did not work when I hit the desktop was the network adapter. By default, Hyper-V uses a synthetic network adapter, which requires you load integration components. From the read-me for the Linux integration components (downloadable from http://connect.microsoft.com):
When installed into a virtual machine running a supported Linux operating system, the Linux Integration components provide the following functionality:
· Driver support for synthetic devices: The Linux integration components include support for both the synthetic network controller and synthetic storage controller that have been developed specifically for Hyper-V. These components take advantage of the new high-speed bus, VMBus, which was developed specifically for Hyper-V.
· Hypercall adapter: The Hypercall adapter is a thin layer of software that sits underneath the Xen-enabled Linux kernel, and translates the Xen-specific virtualization function calls to Microsoft Hyper-V hypercalls. This results in faster performance for the Linux virtual machine.
· *BETA* Mouse Support: Support for the synthetic mouse device has been added in the form of an early “preview” driver. This new mouse support allows the mouse to move in and out of the window without having to use the CTRL-ALT-LEFTARROW key command to break out.
· *BETA* Fastpath Boot Support: Support for faster single disk configurations has been added to the RC2 release. Boot devices now take advantage of the storage VSC to provide enhanced performance.
In other words, it makes everything go faster. I don’t know if these components only work with SUSE Linux Enterprise Server 10, but the read-me does mention that "Integration Components for Red Hat Enterprise Linux 5 will be available in a future update."
The install procedure looked too complex for a Saturday evening, so I will give you the workaround that (should) work on all distributions, whether or not integration components are available. Shut down the VM, go into the properties, and add a legacy network adapter.
Once back in the running OS, I had to run the two following commands to get an IP address, and then networking worked fine:
sudo /sbin/ifconfig eth0 up
The other thing that does not work is sound, but that is because Hyper-V is a server product, and in the datacenter, no-one can hear you beep. With Windows, you can get sound by RDP-ing into the VM (steps courtesy of James O’Neill here), but beats the heck out of me how you might get it to work on Linux. Other than that, OpenSUSE 11 works like a champ, with no wrangling needed to get it up and running.
I’ve done a ton of installs of Ubuntu (for the last several versions) in Virtual PC 2007 here: http://blogs.technet.com/seanearp/search.aspx?q=ubuntu&p=1. All have had varying levels of success, and all of them have required a ton of tweaking to get running. In Hyper-V, install was a snap. The only snag was the fact that Ubuntu defaulted to a screen resolution of 1600×1200, which was much larger than my physical monitor, so I had to scroll around quite a bit during initial setup. Once I logged on, I was able to change the resolution through the GUI, and all was well. As with OpenSUSE, requires the Legacy Network Adapter to be able to browse the Internet.
You can read about my attempts to install various version of Fedora on Virtual PC 2007 here: http://blogs.technet.com/seanearp/search.aspx?q=fedora&p=1. All of them have required tweaking to get things like the mouse to work or the kernel to boot. On Hyper-V, Fedora 9 x64 installs (just like OpenSUSE and Ubuntu) with no problems at all. Like Ubuntu, it defaulted to a strange screen resolution (1152×864), but I was able to change the resolution in the GUI with no problems. Fedora x64 works just fine on Hyper-V as well!
I will leave you with a screenshot of the Hyper-V manager showing me running with a mix of 32-bit and 64-bit virtual machines, both Linux and Windows, and all working like a champ. How’s this for the ultimate geek playground?!?!? I can setup and tear down machines at will, play with them, and practice setting up networks, all on a quite-responsive Hypervisor. Good times!
Remember… just because it isn’t supported, doesn’t mean it won’t work. (Just don’t call Microsoft looking for support 😉