To ensure pinning and exclusive affinity of all vCPUs in the data plane VNF-C, set the VM configuration parameter sched.cpu.latencySensitivity to High. This configuration also disables the interrupt coalescing and Large Receive Offload (LRO) automatically, which is not an issue, because data plane intensive VNF-Cs use DPDK and VMXNET3 DPDK poll mode driver for their data plane intensive vNICs.
To set a VNF-C for CPU affinity, follow these steps:
-
In the vSphere Web Client, right click the VM and select Edit Settings.
-
Select Virtual Hardware.
-
Set the CPU and memory reservations of the VM to their maximal value.
-
Set the CPU limit to Unlimited.
-
Click VM Options and select Advanced.
-
Scroll down to Latency Sensitivity and select High from the drop-down menu.
The vCPUs are pinned and receive an exclusive affinity to a complete CPU core as opposed to a hyperthread. This functionality reduces the risk of two heavy processes competing for a hyperthread resource on the same CPU core, therefore reducing the effective CPU cycles available to each vCPU.
Summary of Recommendations:
-
Set the VM CPU and memory reservation to maximum and the CPU limit to unlimited.
-
Set sched.cpu.latencySensitivity to High for data plane intensive workloads.