Thursday, 22 April 2010

XenApp 6 servers in 20000 state - “An error occurred while making the requested connection”

A frequent error when establishing new farms and servers appears to be servers that have a bad licensing state.  The error you get when trying to launch applications is “An error occurred while making the requested connection”.


To test whether your farm is in this state, open an administrative command prompt on the problem server and run the command:

query farm /load

(or qfarm /load)

If the server you are launching from has a load of 20000, it is not licensed properly.


There are a few different reasons why this might happen.  This is not supposed to be a complete guide, but these are certainly things to try.  After each step, try rerunning the qfarm /load command.  If it goes down to zero, it looks like you have a licensed server.

  • Obvious things first – do you have a license server?!  This is not Terminal Services licensing, this has a grace period of 120 days.  Citrix licensing has no grace period as such (except when your license server fails after previously working, when you get about a month).  I posted a guide about creating a license server here.  Make sure you actually have a working server, that you have installed some real Citrix licenses to it, and that its a modern version.
  • When you are specifying the license server name, don’t fully qualify it – so say “servername”, not “”
  • Look at the Dashboard on your licensing server and make sure the SA date is at least “2010.0317”. 
  • Just in case, sort your TS licensing out while you’re at it! 
    • Click Start,  Administrative Tools, Remote Desktop Services, RDS Host Configuration
    • Click Licensing Diagnosis
    • You should see a number of CALs available to clients and a nice green tick at the top of the screen.
    • Check the users you are testing with are actually in the Remote Desktop Users group on the server.
  • Check with telnet that you can connect to your license server from your Citrix server on port 27000 (or whatever you selected as the licensing port).  Could be a firewall issue on the licensing server.
  • Check you have enabled remote access on the server!!  Click Start, right click Computer, Click Remote Settings and make sure the second, less secure option is selected:

Windows 2008 r2 remote settings

  • Did you specify a license server on installation of the server you’re having trouble with?  If you did, check the server’s console (by plugging in a monitor, using ILO or looking on the VMware\XenServer console) to make sure it is not coming up with an error saying “Citrix XenApp cannot contact the license server…”.  You never know, you might have made a typo.
  • Check the value LSName at this registry location on the server:
  • Try running the XenApp Server Role Manager from the Start Menu on the server with the problem and disjoining the server from the farm, then rejoining, being very careful to get the licensing information right.
  • Try adding another server to the farm (I had one farm where nothing worked until a second server was added…), again getting the license bit right.  See if that server works.  If it does, its something you did on the first one.
  • Change the Load Evaluator your server is using to the Default one instead of Advanced (this was a problem in the Preview edition of XenApp 6, I don’t know if it is in the final release).
  • Set the licensing information for the farm in Group Policy…image
    • Open the Citrix Services Delivery Console
    • Expand the farm and click the Policies node
    • Assuming you only have the Unfiltered policy, select the computer tab, Unfiltered and click Edit.  If you have multiple policies, you might have to do this in all of them, depending on the make-up of your policy structure. 
    • Leave “Enable this policy” ticked and click next
    • Click Licensing on the left.  Click the Edit or Add button by the server host name and ports and enter the correct details.
    • Click Server Settings on the left hand side and click Add/Edit.  Select the product version you have licenses for in the drop down.  This should be the version you have licenses for on the license server. 
    • Click Save
    • You should now see the settings you just entered in the Summary section of Unfiltered. 
    • On the problem server, run gpupdate /force and reboot.
  • Try installing a new test license server in case the problem is there, especially if you have an old version installed.
  • Check the forums!


Anonymous said...

Great post. It helped in solving my issue

Anonymous said...

I appreciate you taking the time to post this! It got me pointed in the right direction for troubleshooting.

Thanks from San Diego

AV said...

Great step by step instructions. This made clear to me that entering the license server is now moved in this version to the policy settings and where to find them. Thx alot!ç

the rainbowarrior said...

in my case it was the XML service that needed to be trusted.
The hint was in initial display before the error
links in
Further, I also had to set RequireLaunchReference=off - but not sure if this helped.
XenApp 6 platinum is difficult to configure - fundamentals edition is was easy to setup.

Sharon said...

Your blog was very helpful giving me ideas. I went thru your suggestions, but still had the same error. I found I was getting the error because I changed the Port from 27000 to 27001. I set a policy in the License Server Port to a value of 27001 and set the License server host name to my server name everything started working. Thanks!

Post a Comment