Virtual Machine performance charts for CPU Usage metrics in VM's displays a different value in than in Guest OS
book
Article ID: 326238
calendar_today
Updated On:
Products
VMware vSphere ESXi
Issue/Introduction
This KB explains how the CPU values are calculated from point of view of the Hypervisor.
Symptoms:
Virtual Machine performance charts for CPU Usage metrics in VM's displays a different value in than in Guest Operating System
For example a VM will show CPU Usage MHz @ 70% however inside vm CPU Usage in MHZ will be @ 40%.
Environment
VMware vSphere ESXi 6.7
VMware vSphere ESXi 6.5
Cause
This difference will appear when the VM have additional entries added in the virtual machines configuration file. (vmx)
ethernetX.ctxPerDev = "1"
sched.cpu.latencySensitivity.sysContexts = "<no of threads>"
Hypervisor will spawn multiple worldID in behalf of the VM .Most of the worldID's are not CPU intensive and they will not reflect CPU usage.
However the worldID like sysContext and CtxPerDev are processes that help the Hypervisor to accelerate the packet handling.
For Example:
2x VCPU with 2x Nics
VCPU 1 usage is 40% and VCPU 2 usage 40% = 40 + 40 = 80%
Nic1 usage is 40% and Nic 2 is 20% = 40 + 20 = 60%
Total CPU usage = 140 / 2(vcpus)
Resolution
Braodcom's Engineering is aware of this and the behaviour will be modified in a future release. A new counter will be added in future release to include a new CPU counter that sums vCPU and does not include VMX CPU usage, effectively excluding the CPU overhead.
Workaround:
Use #esxtop to determine the correct values.
Additional Information
Impact/Risks: This can trigger an alarm as the value can rise over 100%