Image of Android Wireless Application Development
Image of Beginning Google Maps API 3
Image of Advanced Programming in the UNIX Environment, Second Edition (Addison-Wesley Professional Computing Series)
Image of Modern Operating Systems (3rd Edition)

Nesting RHEL7 KVM on VMware Workstation 12

Recently I wished to build a Red Hat Enterprise Linux 7 (RHEL7) appliance with 2 KVM-virtualized guests. Essentially a type 2 hypervisor (VMM) on top of another type 2 hypervisor.

I installed RHEL7 on VMware Workstation 12 and configured it as a Virtualization Server. It was a smooth install without any issues. However I was surprised to find that KVM (Kernel-based Virtual Machine) simply did not work at all and lsmod did not even list the KVM kernel modules.

It turns out that you need to do two changes to your RHEL7 guest configuration file in order for KVM support to be enabled in RHEL7.

The first change requires you to manually edit the RHEL7 guest configuration file, i.e. the file ending in .vmx and add the following directive anywhere in the file:

apic.xapic.enabled = "FALSE"

The second required change can be done from the RHEL7 guest VM Settings pane in VMware Workstation. Go to VM > Settings > Options > Hardware > Processors and tickbox the Virtualize Intel VT-x/EPT or AMD-V/RVI option as shown below:

When you start up the guest after making these two changes, check that the kernel sees virtualization support and that the appropriate kernel drivers have been loaded.

Another useful command for checking virtualization support is the virt-what command:

As you probably know, Linux kernel modules support command line parameters which can be used to configure various settings in a driver. For example, to see the current settings for the kvm-intel module, use the modinfo utility as shown below:

KVM does not populate /sys/hypervisor. As far as I know, Xen was/is the only hypervisor to do so.


Leave a Reply