Virtual Machine Hypervisor: A Comprehensive Guide

The Pervasive Role of Hypervisors
Hypervisors are the foundational technology enabling virtual machines, and their application extends far beyond traditional server environments.
It's highly probable that you interact with a hypervisor on a daily basis without realizing it. Furthermore, their increasing importance suggests widespread adoption is imminent for those not currently utilizing them.
Understanding Hypervisor Functionality
Essentially, a hypervisor functions as software operating independently of any guest operating system. Its primary role is to intercept instructions directed towards the computer’s underlying hardware.
The name "hypervisor" originates from the hierarchical structure within an operating system’s kernel. It operates at a privilege level exceeding that of the "supervisor" mode, thus the designation "hyper-visor."
This elevated authority allows the hypervisor to manage and allocate hardware resources efficiently among multiple virtual machines.
Visual Representation
Image via striatic on Flickr
Understanding Hypervisors
A hypervisor, frequently referred to as a Virtual Machine Manager (VMM), is fundamentally designed to enable the concurrent operation of multiple operating systems on a single physical hardware infrastructure. Traditionally, operating systems are built with the expectation of a direct, one-to-one correlation with the underlying hardware. However, modern processors boasting multi-core architectures and substantial RAM capacities facilitate the seamless execution of numerous operating systems simultaneously.
How Hypervisors Function
The hypervisor effectively abstracts the operating system (OS) from the hardware. It manages the allocation of hardware resources – including CPU time, memory, GPU access, and other components – to each running OS. This resource management functions much like a traffic controller, ensuring fair and efficient access. Each OS managed by the hypervisor is designated as a guest OS, while the hypervisor’s own operating system, if present, is known as the host OS.
Due to its intermediary position between the guest OS and the hardware, a hypervisor can support a diverse range of guest OSs, limited only by the system’s capacity. It’s common to run different operating system types concurrently, such as Windows, macOS, and Linux.
Portability Advantages
This separation of hardware and software also enhances portability. The hypervisor’s role as an intermediary simplifies the process of migrating virtual machines between different computers. This often eliminates the need for reinstalling drivers or updating the guest OS. Users who have transferred VirtualBox virtual machines to different hardware may have already experienced this benefit.
From the perspective of the guest OS, the transition can be seamless, even if the host OS and underlying hardware are entirely different.
Security Benefits of Virtualization
Virtualization offers significant security advantages. When evaluating potentially harmful software, it is advisable to do so within a virtual machine rather than directly on the host OS. Should the guest OS become compromised by viruses or malware, the host OS remains protected, provided shared folders or network bridges are not utilized to connect the two environments.
The inherent isolation between the operating systems – their lack of awareness of each other’s existence – contributes to a safer computing experience.
Popular Hypervisor Options
Several widely used hypervisors are available, including VMware ESXi, Xen, Microsoft Hyper-V, VMware Workstation, Oracle VirtualBox, and Microsoft VirtualPC. Each of these solutions empowers users to virtualize one or more operating systems on a single hardware platform.
Categorizing Hypervisor Architectures
Hypervisors are fundamentally classified into two primary categories, each with distinct characteristics and applications.
Type 1 Hypervisors: Bare Metal
Also known as bare-metal hypervisors, Type 1 installations occur directly on the hardware of a computer system. This architecture bypasses the need for a traditional host operating system.
The hypervisor gains direct control over hardware resources and features. Key benefits include efficient operation of multiple operating systems concurrently and enhanced portability across different hardware platforms.
Due to their security features and hardware independence, bare-metal hypervisors are frequently deployed in server environments. This allows for seamless migration between hardware in the event of failures.
Notable examples of Type 1 hypervisors include VMware ESXi, Citrix XenServer, and Microsoft Hyper-V.
Type 2 Hypervisors: Hosted
Type 2 hypervisors, often referred to as hosted hypervisors, represent a more common virtualization approach for many users.
These hypervisors function as software applications installed within an existing host operating system. While capable of running multiple operating systems simultaneously, they do not possess direct hardware access.
This reliance on a host OS introduces overhead, potentially limiting the performance of guest operating systems. Furthermore, a host system crash can result in the inaccessibility of virtual machines.
Type 2 hypervisors are well-suited for scenarios requiring testing of various operating systems within environments like Windows, macOS, or Linux.
Popular examples include VMware Workstation, VMware Parallels, Oracle VirtualBox, and Microsoft VirtualPC.
The Evolving Landscape of Hypervisors
Currently, the majority of hypervisors are implemented in large server environments or utilized by individual users for compatibility with older applications or for experimenting with alternative operating systems.
However, this paradigm is beginning to shift, as evidenced by recent iterations of Android and speculation surrounding Windows 8.
Android as a Hypervisor
Android leverages a Linux kernel to facilitate communication with hardware and manage system-level processes.
User-facing applications are then executed within a virtual machine known as Dalvik.
Although Android doesn't permit the concurrent operation of multiple operating systems, its architecture closely resembles that of a Type 1 hypervisor.
The underlying Linux host remains largely invisible to the average user, unless the device is rooted for advanced access.
Windows 8 and the Potential for Hypervisor Integration
Reports suggest that Windows 8 may function as a guest operating system running atop Microsoft’s Hyper-V platform.
Hyper-V would assume responsibility for hardware management and essential background tasks, including data backups and file system integrity checks.
This approach, mirroring Android’s design, could enhance portability, flexibility, and security within the operating system.
Furthermore, it would enable a fully portable Windows 8 installation, allowing users to seamlessly transfer their environment between different computers.
Hypervisors in Web Server Environments
Web servers will continue to rely on hypervisors to optimize hardware utilization and minimize operational expenses.
If you utilize shared web hosting from a prominent provider, you are likely already operating on a Type 1 hypervisor without realizing it.
With robust server hardware, bare-metal hypervisors can significantly expand capacity, potentially supporting thousands of operating system instances.
This approach not only reduces hardware acquisition costs but also substantially lowers energy consumption and cooling requirements compared to traditional server deployments.