Convert XEN HVM to PV

Overview

This procedure gives a very simple way of converting a HVM Xen image to paravirtualised (PV) one.

Rationale

Most current operating systems have paravirtualisation support built-in, and they are able to detect whether theye are running in either HVM or PV mode.

Installing an operating system is easier from an ISO image with HVM mode.

The following operating systems have been tested with this procedure:

    • Ubuntu 16.04 LTS Desktop
    • Ubuntu 16.04 LTS Server

Restrictions

6.70 Oracle Linux 7 and RedHat Enterprise Linux 7 Not Supported For PV Guests says:

Although Oracle Linux 7 and RedHat Enterprise Linux (RHEL) 7 are supported for both hardware virtualization (HVM) and hardware virtualization with paravirtual drivers (PVHVM), it is not possible to run either of these operating systems as paravirtualized domains (PVM). This is due to kernel restrictions in both Oracle Linux 7 and RHEL 7.

Procedure

Disable HVM Mode

Disable HVM mode by removing the following line from the Xen configuration file:

builder="hvm"

Enable PV Mode

Enable PV mode by adding the following lines to the Xen configuration file:

type="pv" bootloader="pygrub"

Verification

After the Xen image has been started, run the following command:

dmesg|grep -i paravirtual

The output should be similar to the following:

[ 0.000000] Booting paravirtualized kernel on Xen