
People new to the virtualization space could get very frustrated when they find out that their Hypervisor of choice preforms much worse than a bare-metal installation. Haven’t the vendors and independent analysis like Project Virtual Reality Check stated that there is no longer any excuses for not running Citrix XenApp on a Hypervisor. The latest numbers shows that the performance are almost the same on XenServer, VMware and Hyper-V.
That being said, to get these high performances requires that you have done your homework and implemented all the Best Practices. Unfortunately there is way to many bugs out there and I’m not even going to start…but I have almost begged Citrix to pay more attention to their own Support Forum in this post.
In this post I’m going to share some important tunings related to poor network performance on Citrix XenServer 5.x family.
Disable Task Offload :
For Windows 2003 VM’s you will need to create a registry key to DisableTaskOffload – REG_DWORD = 1 under HKLMSYSTEMCurrentControlSetServicesTcpipParameter. The easiest way is to create a Group Policy to push this registry key.
Disable CheckSum Offload :
The second fix you should try if you still have poor network performance is to Disable Checksum on the XenServer interfaces, both the Virtual (VIF) and the Physical (PIF). Be aware that you don’t need to restart the XenServer or the VM’s. This script will do this automatically on all you network interfaces in your XenServer Pool.
echo Setting checksum off on VIFs
VIFLIST=`xe vif-list | grep "uuid ( RO) " | awk '{print $5}'`
for VIF in $VIFLIST
do
echo Setting ethtool-tx=off and ethtool-rx=off on $VIF
xe vif-param-set uuid=$VIF other-config:ethtool-tx="off"
xe vif-param-set uuid=$VIF other-config:ethtool-rx="off"
done
echo Setting checksum off on PIFs
PIFLIST=`xe pif-list | grep "uuid ( RO) " | awk '{print $5}'`
for PIF in $PIFLIST
do
echo Setting ethtool-tx=off and ethtool-rx=off on $PIF
xe pif-param-set uuid=$PIF other-config:ethtool-tx="off"
xe pif-param-set uuid=$PIF other-config:ethtool-rx="off"
done
Note :
Please note that this script is provided “as is” and that using this is at your own risk. Please feel free to leave comments below regarding bugs & suggested improvements in future releases.
5132 other Citrix Community members have already downloaded the eBook. It contains a lot of helpful information for both beginners and experts. Combined with the 7 day eCourse you will have a solid foundation to get certified as a Citrix Administrators. Check out some of these testimonials:
“I’ve used the the Hands On Guide for XenApp 5.0 extensively as a reference in my work. It’s been a great help to me”. John Martz – Illinois, USA
“Your guide was very helpful for me to get started with XenApp 5 and XenServer. I have deployed XenApp 5 using this on production environment and all looks good. Many thanks and keep up the good work!!!”. Manish N. Dwivedi – India
“Your web site has helped me greatly as I have now developed a test Citrix farm using your guide, this proved to be a great reference to follow when setting up a new 2008 environment with XenApp 5.0, not only does it cover installing XenApp but gives an insight into XenServer. Would highly recommend this web site and eBook to anyone from beginner to expert”. Nick Rimmer – Scotland
“I truly appreciate the work and the amount of time you spent in creating this amazing book. I found your book an excellent start to the world of Citrix XenApp. What I truly appreciate the most is the step by step instructions in about every little detail that goes with XenApp installation and settings. I wish I had your book a few years back when I first start learning about Citrix it would saved me a lot of hours and frustrations. Keep up the good work!”. Adam Tigris – Toronto

If you like this post enter your information below to receive our FREE "Citrix XenApp 5.0 on Windows 2008" eBook and a 7 day eCourse with Tips & Tricks never revealed before.

Are you setting up a new Proof of Concept 







{ 27 comments… read them below or add one }
Regarding the disable task offload key –
What is the actual effect of that key? By which I mean, if I set it via GPO and it affects a non-virtualized server, will I be doing damage to anything?
Hi Jeremy,
I would recommend testing this on VM’s you have problems with. The best would be GPO Preferences – Item-Level Targeting to e.g. check if OS = Windows 2003 and Citrix Tools is installed.
The Citrix Support Forum thread.
Eric
if you use provisioning service in combination with Xen servers also check this key.
HKEY_LOCAL_MACHINESystemCurrentControlSetServicesxenevtchnSetFlags 30000 hex.
This effectively disables TSO and DMA on the Xen Tools.
http://support.citrix.com/article/CTX125157
Thanks Evert,
According to the KB this applies to all VM’s running on XenServer 5.0 and 5.5
Eric
Thanks Eric!
How do you execute the mentioned script ? In a .sh file ?
Thanks
Hi Spear,
You could just copy & paste it into the XenServer Console or do SSH to the XenServer.
Hi guys thank you for the TIPs
can you kindly share your experience on this:
http://forums.citrix.com/message.jspa?messageID=1482685#1482685
Thank you if you will
Roberto
Hi Roberto,
I would recommend you forwarding the Citrix Forum Thread to @CitrixSupport on Twitter
Trond,
I´ve got some Windows 2k3 and Windows 2k8 VMs running on the Xenserver 5.5 update 2 and Xenserver 5.6.
These settings apply to Xenserver 5.5 update 2?
I did network tests with iperf and had good results, like this:
[ ID] Interval Transfer Bandwidth
[1860] 0.0-10.0 sec 113 MBytes 94.6 Mbits/sec.
Thanks,
Hi Luiz,
This apply to XenServer 5.x and Provisioning Services VM’s running Windows 2003 x32. If you don’t experience slow network performance I would recommend you staying with your current configuration.
If I have a pool of 9 XenServers, do I just run the checksum script/commands on 1 XenServer or all 9?
Hi Ray,
As long as all the XS servers are in the same pool you’ll only need to run it from one XenServer console. Be aware that we are setting checksum off on both physical and virtual interfaces, which means you’ll need to run the script each time you add a new VM. The best solution would be to create a script that does this automatically.
I have been using XenServer for a little while now, first on 5.5 and now 5.6. I have always had an issue where uploading file from a workstation to a Server 2003 VM was fine, but downloading from that VM was slow. If, instead, I consoled into the VM and “pushed” the file to the workstation it worked speedily.
I tried the registry fix and now I’m getting full bandwidth in both directions. Thanks!
Awesome Francois
xenapp plugin freezes when i access it on a pvs xen desktop image
I have 6 xen servers on 6 servers in a cisco enclosure and a 1 gig connection
what can i do
Hi Hanno,
Need some more information here on XD version, Plugin etc. The Citrix Online or Offline plugin is freezing inside of the XD when you try to do a ICA in ICA session?
Hi
Regarding the script.
I just spoke to Citrix and the say that you have to reboot the servers before the changes will work.
So now I’m a little confused.
Hi Thomas, probably depends on who you are talking to at Citrix. Anyway it have worked for me without reboot. Just keep in mind that you have to run this script every time you add a new VM, because the script is also setting this on the VIF adapter (Virtual).
Hello,
This post, save my life!!

Hi,
Can you elaborate on the Network Slowness that this is meant to address? In my situation I have two XenServer hosts running v5.6.0-31188p with each running 2 P2V converted VM’s running XenApp 5. Both Hosts are connected to a SAN via a separate Gb LAN. For some reason when more than 2 users land on the same server at the same time (give or take a minute) it can take as long as 10 minutes for them to get logged in. But if a single user logs on it can be a fast as 35 seconds. However I don’t have this problem on my Physical XenApp servers.
Any thoughts would be appreciated.
Hi Scott, please check the email I sent you
Trond, I’m sorry but I did not get your email. I’ve checked my AntiSpam system and didn’t see anything come in from you. You sent it to administrator@bathweg.com?
Thanks,
Eric,
Thank you so much for the assitance you provided in your email.
Once I was able to test and verify that my network was functiioning as expected, I was able to key in on one of your suggestions pertaining to the vCPU assignment. I had never read or came across anything mentioning this very important detail until you contacted me.
As I stated in my original posting, I had converted a Physical Xenapp server to a Virtual Machine (4) and other than removing the left-over drivers, in my mind the options that remained (memory config and CPU’s etc) should have provided a snappy workload that either met or exceeded the physical server’s performance. What I exerienced was less than stellar. But after scaling back the vCPU’s to 2 (from 4), all of my login issues were gone and they’ve been fine since. I was even able to scale back the memory consumption to save even more resources on my hosts. Truth be told, my Xenapp VM’s are snappier than my Physical Xenapp servers.
So thank you for your help and keep up the great work you’re doing here.
Glad I could help you solve this Scott
Eirik -
I have an issue where I have 915Blades connected through a 10GB network. Running benchmarks on my vm’s I noticed that my disk I/O is really bad. I get about 20MB/sec average. I have vm’s on EQLogic and NetApp and still get bad disk I/O. I’m wondering if implementing the Checksum Offload would help resolve my problem. Have you ever encountered what I’ve just written? Would like your feedback.
Hi Lee, I have not experienced this. Please try a iperf against physical and virtual host to see if there’s amy difference. cmd : iperf -c ipadr -f M -t 30 -i 1. Download iperf here : https://nocweboldcst.ucf.edu/files/iperf.exe
{ 3 trackbacks }