What is paravirtualization?

Paravirtualization is an enhancement of virtualization technology in which a guest OS is modified prior to installation inside a virtual machine (VM) in order to allow all guest OSes within the system to share resources and successfully collaborate, rather than attempt to emulate an entire hardware environment.

With paravirtualization, virtual machines can be accessed through interfaces that are similar to the underlying hardware. This capacity minimizes overhead and optimizes system performance by supporting the use of VMs that would otherwise be underutilized in conventional or full hardware virtualization.

The main limitation of paravirtualization is the fact that the guest OS must be tailored specifically to run on top of the virtual machine monitor (VMM), the host program that allows a single computer to support multiple, identical execution environments. Paravirtualization eliminates the need for the virtual machine to trap privileged instructions.

Trapping, a means of handling unexpected or unallowable conditions, can be time-consuming and can adversely impact performance in systems that employ full virtualization.

How does paravirtualization work?

Paravirtualization attempts to resolve issues found in full virtualization. The primary difference between paravirtualization and full virtualization is the ability to make modifications to the guest OS in paravirtualization.

Furthermore, in paravirtualization, the guest OS is aware it is being virtualized. In full virtualization, the unmodified OS is unaware it its being virtualized and sensitive OS calls are captured and translated using binary translation.

By granting the guest OS access to the underlying hardware, paravirtualization enables communication between the guest OS and the hypervisor, thus improving performance and efficiency within the system.

More specifically, the paravirtualization process consists of the guest OS being modified specifically for installation on a VM. This is necessary because unmodified guest OS are unable to run on a VMM. The intent of the modification is to decrease the execution time required to complete operations that can be problematic in virtual environments.

In paravirtualization, the guest kernel is modified to run with the hypervisor. This frequently involves removing operations that only run on ring 0 of the processor with calls to the hypervisor, or hypercalls.

The hypervisor responds by performing the task for the guest kernel and supplying hypercall interfaces that can be used to complete other important kernel operations -- such as interrupt handling, time keeping and memory management.  

Uses of paravirtualization

Paravirtualization is an expansion of a technology that has existed for years in the IBM operating system. Xen, an open source hypervisor, incorporates paravirtualization. Xen virtualizes the memory and processor using an altered Linux kernel. It also virtualizes the I/O using custom guest OS device drivers.

Paravirtualization offers various performance advantages as well as efficiencies that offer improved scaling. It is useful in a variety of technical fields, including:

  • disaster recovery
  • capacity management
  • separating test systems and development environments
  • transferring data from one system to another

Advantages and disadvantages of paravirtualization

Advantages of paravirtualization include:

  • Direct communication between the guest kernel and the hypervisor improves performance levels.
  • The thin software layer created in paravirtualization controls virtual server traffic by allowing a single guest OS to gain access to the physical hardware device while ceasing access for all other guest OS.
  • Since paravirtualization does not attempt to fully rebuild the hardware, there is lower virtualization overhead.
  • Paravirtualization does not include device drivers because it utilizes the drivers already present in the guest OS. Therefore, organizations can take full advantage of the hardware in the server instead of being limited to hardware with available drivers, as is the case in full virtualization.

Disadvantages of paravirtualization include:

  • Modifications of the guest OS are necessary for any interaction with the paravirtualization interfaces to take place, thus limiting support to open source OSes, such as Linux.
  • Since paravirtualization cannot perform with unmodified guest OS, its compatibility and portability is minimal with systems like Microsoft Windows.
  • Significant support and maintenance issues may arise since the production environment requires complex guest kernel modifications.
This was last updated in October 2021

Continue Reading About paravirtualization

Dig Deeper on Containers and virtualization

Software Quality
  • How to test a predictive model

    Strategies for testing predictive models and analytics emphasize data quality, real-time testing and code redundancy, as well as ...

  • The dos and don'ts of visual testing

    The visual aspect of an application is an important part of UX. Defects can potentially result in lost sales and damaged ...

  • 3 QA testing tools to consider

    QA testers need to be able to put applications and APIs through their paces. Here are some examples of tools that can help with ...

App Architecture
Cloud Computing
Data Center