Technical information

Performance Best Practices for VMware vSphere 4.0
30 VMware, Inc.
ESX VMI support can be enabled for a virtual machine through the vSphere Client by selecting Edit virtual
machine settings, choosing the Options tab, selecting Paravirtualization, then marking the box next to
Support VMI Paravirtualization. Enabling VMI for a virtual machine reduces the number of available PCI
slots in the guest operating system running in that virtual machine by one. There is no performance benefit to
enabling VMI for a virtual machine running a non-VMI operating system.
Kernel support for VMI is included in some recent Linux distributions (Ubuntu 7.04 and later and SLES 10 SP2,
for example), and can be compiled into other Linux distributions, typically by compiling the kernel with
CONFIG_PARAVIRT and CONFIG_VMI. No Microsoft Windows operating systems support VMI. Check the
VMware Guest Operating System Installation Guide to see which VMI operating systems are supported in ESX.
More information about VMI can be found in
Performance of VMware VMI (http://www.vmware.com/resources/techresources/1038)
and the Paravirtualization API Version 2.5 (http://www.vmware.com/pdf/vmi_specs.pdf).
For best performance, consider the following regarding enabling VMI support:
If running 32-bit Linux guest operating systems that include kernel support for VMI on hardware that
does not support hardware-assisted MMU virtualization (EPT or RVI), enabling VMI will improve
performance.
VMI-enabled virtual machine always use Binary Translation (BT) and shadow page tables, even on
systems that support hardware-assisted MMU virtualization. Because hardware-assisted MMU
virtualization almost always provides more of a performance increase than VMI, we recommend
disabling VMI for virtual machines running on hardware that supports hardware-assisted MMU
virtualization. (No kernel change is required in the guest, as the VMI kernel can run in a non-VMI enabled
virtual machine.)
Measuring Performance in Virtual Machines
Be careful when measuring performance from within virtual machines.
Timing numbers measured from within virtual machines can be inaccurate, especially when the processor
is overcommitted.
Measuring performance from with virtual machines can fail to take into account resources used by ESX
for tasks it has offloaded from the guest operating system, as well as resources consumed by virtualization
overhead. For additional information see KB article 2032, listed in “Related Publications” on page 8.
Measuring resource utilization using tools at the ESX level, such as the vSphere Client, VMware Tools,
esxtop, or resxtop can avoid these problems.
N
OTE One possible approach to this issue is to use a guest operating system that has good timekeeping
behavior when run in a virtual machine, such as a guest that uses the NO_HZ kernel configuration option
(sometimes called “tickless timer”) or the VMI paravirtual timer. More information about this topic can
be found in Timekeeping in VMware Virtual Machines
(http://www.vmware.com/pdf/vmware_timekeeping.pdf).