Persistence on NetScaler

Some transaction based applications require persistence. For example, banking sites are interactive programs based on user input and selections. User logs on by providing a username and password and then the user can do a variety of tasks, such as checking account balance, transferring fund, etc. If persistence is not configured, user might have authenticated with Server 1, but his next request may go to Server 2 or Server 3.

In this case, the application will reject the user request since Server 2 or Server 3 does not have user’s transaction state & authentication details. If persistence is configured, all subsequent requests from the user will be directed to the server which got selected in the first request. In this example, all requests will be forwarded to Server 1.

Persistence can be configured for the following protocols: HTTP, SSL, IP, TCP, UDP, SIP, and RTSP. The administrator can configure persistence interval and persistence type based on the application requirement. NetScaler supports 10 persistence types. Netscaler can support 250K Persistent session for a core and some persistence types (CookieInsert) depends on the Netscaler memory limit. If persistence is configured for a particular domain, it takes precedence over the configured GSLB method. If the configured persistence applies to a site that is down, the NetScaler appliance uses a GSLB method to select a new site, and the new site becomes persistent for subsequent requests from the client.
Citrix recommends to configure the Cookie Insert persistence method on the NetScaler appliance when load balancing Citrix Web Interface servers.

Some persistence types:
Source IP, Cookie Insert, SSL Session ID, URL Passive, Custom Server ID, Rule, DESTIP, SRCIPDESTIP

To configure Cookie persistence by using commands:

> add lb vserver V1 http 10.120.80.50 80 -persistencetype COOKIEINSERT
Done
>
> add service S1 200.205,215.1 HTTP 80
Done
>
> add service S2 200.205,215.2 HTTP 80
Done
>
> add service S3 200.205,215.3 HTTP 80
Done
>
> bind lb vserver V1 S[1-3]
service “S1” bound
service “S2” bound
service “S3” bound
Done

To verify the cookie value of a service:

>show lb vserver V1

To capture the Service selection counter and Cookie persistence counter from NetScaler shell prompt:

nsconmsg -i V1 -s ConLb=1 -d oldconmsg

To configure Source IP Persistence by using commands:

> add lb vserver V1 http 10.120.80.50 80 -persistencetype sourceIP -timeout 5
Done
> bind lb vserver V1 S[1-3]
service “S1” bound
service “S2” bound
service “S3” bound
Done

To displays persistence session information:

> show persistentSessions -summary

Advertisements

About Murugan B Iyyappan

Working as a Technical Specialist - Citrix solutions architect with 13 years of experience in the IT industry. Expertise in Citrix XenApp and VMware in Windows platform.
This entry was posted in Citrix XenApp. Bookmark the permalink.