Loopback Options When Load Balancing StoreFront Server Group Using NetScaler

Loopback Options When Load Balancing StoreFront Server Group Using NetScaler

book

Article ID: CTX217234

calendar_today

Updated On:

Description

In previous versions of StoreFront such as 2.6 or older, Citrix recommended that you manually modify the hosts file on each StoreFront server to map the fully qualified domain name (FQDN) of the load balancer to the loopback address or the IP address of the specific StoreFront server. This ensures that Receiver for Web always communicates with the StoreFront services on the same server in a load balanced deployment. This is necessary because an HTTP session is created during the explicit login process between Receiver for Web and the authentication service and Receiver for Web communicates with StoreFront services using the base FQDN. If the base FQDN were to resolve to the load balancer, the load balancer could potentially send the traffic to a different StoreFront server in the group, leading to authentication failure. This does not bypass the load balancer except when Receiver for Web attempts to contact the Store service residing on the same server as itself. 

You can set loopback options using PowerShell. Enabling loopback negates the need to create host file entries on every StoreFront server in the server group. 

Example Receiver for Web web.config file:
<communication attempts="2" timeout="00:01:00" loopback="On" loopbackPortUsingHttp="80">

Example PowerShell command:
& "c:\program files\Citrix\receiver storefront\scripts\ImportModules.ps1"
Set-DSLoopback -SiteId 1 -VirtualPath "/Citrix/StoreWeb" -Loopback "OnUsingHttp" -LoopbackPortUsingHttp 81

The -Loopback parameter can take any of the following three possible values:

Value

Context

On:

Changes the host of the URL to 127.0.0.1.  The schema and port (if specified) are not changed.

Cannot be used if SSL-terminating load balancer is used.

OnUsingHttp:

Changes the host to 127.0.0.1 and schema to HTTP and modifies the port the value configured forloopbackPortUsingHttp attribute.

Use only when the load balancer is SSL terminating.  Communication between the load balancer and StoreFront servers is with HTTP.  You can explicitly configure the HTTP port using the -loopbackPortUsingHttp attribute.

Off:

The URL in the request is not modified in any way.

Use for trouble shooting.  Tools like Fiddler cannot capture the traffic between Receiver for Web and StoreFront Services if loopback is set to “On”.

Note: From StoreFront 3.5 and newer, you can enable loopback in the StoreFront Console.