Configuring Persistent Connections Between Clients and Servers

The Citrix NetScaler initially selects a server by using a load balancing method. With persistence configured, enabling the NetScaler to send any subsequent client requests to the selected server, the server can access state information for that client. If persistence is configured, it overrides the load balancing methods once the server has been selected. If the configured persistence applies to a service that is down, the NetScaler uses the load balancing methods to select a new service, and the new service becomes persistent for subsequent requests from the client. If the state of the selected service is “out of service”, it continues to serve the outstanding requests, but it does not allow new requests or connections. After the shutdown period elapses, no new requests or connections are directed to the service and the existing connections are closed.

Configurable Persistence Types

Persistence type Persistent connections
Source IP, SSL Session ID, Rule, DESTIP, SRCIPDESTIP 250 K
CookieInsert, URL passive, Custom Server ID Memory limit. In case of CookieInsert, if
time out is not 0, any number of connections are allowed until limited by memory.

Configuring Persistence Types

If the configured persistence cannot be maintained because of lack of resources on the NetScaler, the load balancing methods are used for server selection. Persistence is maintained for a configured period of time, depending on the persistence type. Some persistence types are specific to certain virtual servers.

Relationship of Persistence Type to Virtual Server Type

Persistence type HTTP HTTPS TCP UDP SSL_Bridge
Source IP YES YES YES YES YES
CookieInsert YES YES NO NO NO
SSL Session ID NO YES NO NO YES
URL passive YES YES NO NO NO
Custom Server ID YES YES NO NO NO
Rule YES YES NO NO NO
SRCIPDESTIP NA NA YES YES NA
DESTIP NA NA YES YES NA

To configure persistence on a virtual server by using the NetScaler command line

At the NetScaler command prompt, type:

set lb vserver <name> -PersistenceType <type>

Example:

set lb vserver Vserver-LB-1 -persistenceType SOURCEIP

Persistence Parameters

Parameters Specifies
Persistence Type
(persistenceType)
Persistence type for the virtual server. The valid options for
this parameter are:
SOURCEIP, COOKIEINSERT, SSLSESSION, RULE,
URLPASSIVE, CUSTOMSERVERID, DESTIP,
SRCIPDESTIP, CALLID, and NONE (default)
Persistence Mask
(persistMask)
Persistence Mask is used to specify if the persistence is
IP-based. The default value is 255.255.255.255. If you set 0
using this parameter the complete IP address is used for
persistence.
Time-out
(timeout)
The time period for which persistence is in effect for a
specific client. The default value is 2 minutes, and the
maximum value that can be configured is 1440 minutes.

To configure persistence on a virtual server by using the GUI configuration utility

  1. In the navigation pane, expand Load Balancing, and then click Virtual
    Servers.
  2. In the details pane, select the virtual server for which you want to configure
    persistence (for example, Vserver-LB-1), and then click Open.
  3. In the Configure Virtual Server (Load Balancing) dialog box, on the
    Method and Persistence tab, in the Persistence list, select the persistence
    type you want to use (for example, SOURCEIP).
  4. In the Time-out and Netmask text boxes type the time-out and netmask
    values (for example, 2 and 255.255.255.255).
  5. Click OK.
Note: After configuring persistence for a virtual server, you can view the
persistence type by viewing the virtual server from the configuration utility or
using the show lb vserver command. You can also use the show ns
persistencesession command to view persistence sessions.





Get the most powerful Persistence Load Balancer here.




It’s powerful!