XenServer Performance and Scalabilitiy Tuning

There have been performance-related issues reported with certain VDI environments where the number of virtual machines running on XenServer was limited to about 60 or 65. Reports of poor performance within the user sessions on those 60 or 65 machines was also reported. When more than 65 machines were loaded on a single XenApp host, it has been noticed that the dom0 was at capacity and the PVS driver showed poor throughput of 4MB/s or less. Once 65 VMs were loaded, the user experience dropped dramatically. This scenario is explained in an article on the Citrix Blogs.


  • PVS 6.1
  • XenServer 6.0.2
  • Provisioned Windows 7 (64 Bit) Clients
  • PVS-Network not separated (10 Gbit Broadcom)
  • XenServer-Host: Dell M910 Blade Server (4*10 Cores, 512 GB RAM)
  • SAN Fibre Channel Connection
  • WriteCache-Method : Cache on device hard disk (SAN Storage)
  • Physical PVS-Server

The more machines that were started the longer it took for the virtual machines to start up. In PVS environments there is inherently have high network and storage utilization and all traffic goes through dom0. The puzzling fact was why dom0 was fully loaded at only 65 machines. The Best Practice Guide states that you should not have more than 70 – 130 machines on one host but starting 100machines should be well within capabilities. The modification of the following two parameters let us start more than 150 machines on the same host, while still showing good performance.

1. Increase the count of vCPUs assigned to dom0 to 8

That can be done by executing the following command on the XenServer console:

/opt/xensource/libexec/xen-cmdline –set-xen dom0_max_vcpus=8 echo ‘NR_DOMAIN0_VCPUS=8′ > /etc/sysconfig/unplug-vcpus

Please note: Before executing these commands the C-STATE Option in the XenServer host BIOS should be disabled if necessary, according to the following article: http://support.citrix.com/article/CTX127395

This article referes to a special type of CPU. If you don’t follow the advice in the article, your XenServer machine may crash.

2. Increase the amount of storage buffer size to the limit of 256

Execute the The following command to increase the buffer size:

/opt/xensource/libexec/xen-cmdline –set-dom0 blkbk.reqs=256

This command improves the storage throughput.

These two modifications allowed for a larger amount of provisionend virtual machines to run on the same host and still provide good performance. In addition, the amount of memory used by dom0 was increased to the maximum of 2940 MB. ( http://support.citrix.com/article/CTX126531)

If you need to tune your XenServer environment using the above modifications keep in mind the following three indicators in order to extrapolate the performance level of your host:

1. Boot time of the virtual provisioned machine (apparent from PVS Target device driver)

2. PVS data throughput (apparent from PVS Target device driver)

3. Load of dom0 (apparent by executing the “Xentop” command on the XenServer console)

These settings should only be used if absolutely needed and should be adequately tested before implementing in a Production environment. The default XenServer settings are still recommended and increasing the count of dom0 CPUs is not supported.

Read the original article here.

Be Sociable, Share!


Comments: 2

Leave a reply »

  • Leave a Reply
    Your gravatar
    Your Name