After upgrading from NetScaler 11.1.56.13 to 12.0 53.12, VSphere might be reporting high CPU for the NetScaler instance. When we check the actual CPU on the NetScaler (Management and Packet), the CPU shows normal. A newly deployed (no load) VPX instance on VSphere shows 50% CPU and when we connect to the GUI it spikes to 90% and above on the VSphere.
This is an expected behavior with latest NetScaler 12.0 build. This is because we have disabled CPU yielding for the VPX. CPU Yielding is a feature that allows the packet engines to idle when there is no traffic. In case you want to over-ride it, you can use CLI command to enable yield:
set ns vpxparam -cpuyield YES
With version NetScaler 11.1, VPX was sharing CPU with other VMs. With NetScaler 12.0 version, VPX will not share CPU by default.
Top command shows 100% CPU utilization: CTX227605
Note: You will also see NSPPE taking up 100% CPU on the other CPU cores, when viewed with the top command. This is also by design. The packet engines (NSPPE) perform their own kernel scheduling services internally and their utilization cannot be monitored with the top command.
High Packet or Management CPU: CTX226784
BACKGROUND: https://docs.citrix.com/en-us/netscaler/downloads/release-notes-12-0-58-18.html
Two New Commands to Control CPU Usage Behavior has been introduced.
set ns vpxparam and show ns vpxparam, control the CPU-usage behavior of VPX instances in VMWare ESX and Citrix XEN environments:
1. set ns vpxparam -cpuyield (YES | NO | DEFAULT)
Allow each VM to use CPU resources that have been allocated to another VM but are not being used.
Set ns vpxparam parameters:
-cpuyield: Release or do not release of allocated but unused CPU resources.
YES: Allow allocated but unused CPU resources to be used by another VM.
NO: Reserve all CPU resources for the VM to which they have been allocated. This option shows higher percentage in hypervisor for VPX CPU usage.
DEFAULT: NO
Note: On all NetScaler VPX platforms, the vCPU usage on the host system will be 100 percent. Type the set ns vpxparam –cpuyield YES command to override this usage.
2. show ns vpxparamDisplay the current vpxparam settings.