Tuesday, September 27, 2011

How-To Configure Citrix Web Interface Zone Preference

This post will illustrate how to configure Citrix Web Interface to direct users to published resources in a particular zone when connecting through a specific Web Interface server.  It applies to web interface 5.2.


1 - Log in to the web interface server and open the Citrix Web Interface Management console.  Right click the site you are going to configure and click on Session Preferences.


2 - Select the Web Interface should override the ICA client name check box.

3 - Edit the SessionUtils.java file located in the C:\inetpub\wwwroot\Citrix\<sitename>\app_code\PagesJava\com\citrix\wi\pageutils folder.
In our case, we're looking to change the client name to "WM_<username>" or "WD_<username>" depending on which web interface server users are connecting to.  "WM_" is for the primary zone and "WD_" is for the backup.  This example will change it for the web interface server serving the primary zone. 

Comment out the following line:

deviceInfo.setClientName( clientName );

and copy the following just beneath it:

//The following two lines have been added in order to change the client name which enables us to set a zone //preference based on client to direct user's to a particular zone when connecting from a specific web interface //server
String userID = accessToken.getShortUserName();
deviceInfo.setClientName("WM_" + userID);

Note
: You cannot change hte length of the client name. For example, WDZO cannot be substituted for WD_

Here is a screenshot of the file when edited for the WI server in the primary zone:



4 - Open the Citrix XenApp Advanced Configuration Console and create a new policy for each zone that will specify zone preference and failover.

The settings are as follows for the primary zone policy:


Apply the policy filtered on the WM_ client name and select the Allow radio button.



5 - Repeat the steps taken on the web interface server on any other web interface servers where a zone preference is needed and edit the policy as necessary for zone preference and failover.

Notes:
You can check to verify your client naming convention is in force by logging into an application served by the web interface server you edited the SessionUtils.java file on. 

You can check the zone preference policy by publishing a test application or desktop and logging into each  web interface server and verify you land on a XenApp server in the zone that the web interface server is serving.

No comments:

Post a Comment