Wedel IT

XenServer c-state or not to c-state

XenServer c-state or not to c-state

We in Wedel IT have done quite a few XenApp projects based on XenServer over the years and we do our best to follow best practice / common practice from Citrix.

Historically we have been told that C-State should be turned off on XenServer’s running XenApp workloads, but this changed from XenServer 6.5 and onwards according to –
Based on this article XenServer is supposed to handle C-states by itself and we can leave it turned on as per default by most hardware manufacturers.

In a project we did for a municipality that had HP360 G9 servers we felt that the user experience was not optimal, it was always OK-ish, but moving from older servers to newer did not seem to give us the user experience we expected. After on-boarding approximately 1000 users to the solution we saw log on times around 35-40 seconds and we had users complaining that applications took a long time to generate reports as well.

In addition our XenServers and virtual machines showed quite high CPU usage as you can see in the graph below.

C-State Enabled – XenServer view

C-State Enabled – Task Manager view

By luck / accident when installing a new server to this deployment we changed the C-state in BIOS to OFF for the new server and immediately it showed significant improved in performance, we changed the rest of the servers 1-by-1 and well the numbers speak for themselves;

C-State Disabled

C-State Disabled – Task Manager view

Logon duration went down to 17 seconds from 35-40 seconds.
Report generation went down to 7 seconds from 50 seconds.
Application launches that previously took a few seconds are now ready in no time.

Does this affect your environment? We are not sure, we have changed the setting at other customer sites with minimal to no difference in performance. Is it worth a try? Most definitely.
Could be different hardware that behaves differently, could be a BIOS / driver firmware that changes the behavior.

We have seen the same performance improvement with both XenServer 6.5 and 7.2.
In addition we’ve been in contact with Citrix’s XenServer team and they were unable to explain the performance gain we saw in this case and unfortunately we didn’t have time to give them access and test both a server with C-state OFF and ON

Seen anything familiar or have any inputs, feel free to get in touch!
Daniel Wedel

Latest Posts