ADC

Share persistent sessions between virtual servers

In some customer environments (telecom and ISP), a single server handles both control and data traffic. For a given client IP address, both control and data traffic have to be directed to the same back-end server. For this, one virtual server is required for handling client authentication traffic, and usually rule based persistency is configured on it. For example, Radius.req.avp(8).value.typecast_text_t’. The second virtual server for handling data traffic. Usually, SourceIP persistence is configured on it.

Previously, persistence entries were local to the virtual server. If you had to apply persistence across multiple virtual servers, you had to add the virtual server to a load balancing group and then apply a common persistence type to the group. This requirement cannot be achieved, because all the virtual servers bound to a load balancing group inherited the persistency configured on the group.

With the persistency sharing between virtual server feature, you can set the new useVserverPersistency parameter for a load balancing group to allow the virtual server in the group to use their own persistency parameters instead of inheriting them from the group settings. You can configure separate rule-based persistency on each virtual server.

Optionally, you can also designate one of the virtual servers in the group as a main virtual server. When a virtual server is designated as a main virtual server, only that virtual server creates the persistence entries, which are used by all the virtual server in the group. If the main virtual server is down, the NetScaler appliance does not create any persistence entries.

Note: Persistence sharing across the virtual servers is supported only for rule based persistency methods. Configure compatible rule based persistence parameters on the member virtual servers.

Example:

Assume v1 and v2 are bound to a load balancing group, v1 is a RADIUS type virtual server and v2 is an HTTP type virtual server. ‘Radius.req.avp(8).value.typecast_text_t’ persistency is configured on v1 and ‘client.ip.src’ is configured on v2.

When traffic flows through the RADIUS virtual server v1, it creates a persistent entry based on the evaluated rule string. Later, when traffic reaches the HTTP type virtual server v2, v2 checks for the persistence entries on the load balancing group and uses the same persistence session to direct traffic to the same back-end server.

Configuring Sharing of Persistent Sessions

To share persistency parameters across the virtual server in a load balancing group, you must first enable the useVserverPersistency parameter and then designate one of the virtual servers in the group as a main server.

To enable the useVserverPersistency parameter by using the command line interface

At the command prompt, type:

set lb group <name> -useVserverPersistency ( ENABLED)
<!--NeedCopy-->

Example:

set lb group lb_grp1 -useVserverPersistency ENABLED
<!--NeedCopy-->

To enable the useVserverPersistency parameter by using the GUI

  1. Navigate to Configuration > Traffic Management > Load Balancing > Persistency Groups.
  2. Click Add to add a new group or select an existing group and click Edit.
  3. Select Use Vserver Persistence.

To designate a virtual server as a main virtual server by using the command line interface

At the command prompt, type:

set lb group <name> -useVserverPersistency ( ENABLED ) -masterVserver <string>
<!--NeedCopy-->

Example:

set lb group lb_grp1 -useVserverPersistency ENABLED –masterVserver vs1
<!--NeedCopy-->

To designate a virtual server as a main virtual server by using the GUI

  1. Navigate to Configuration > Traffic Management > Load Balancing > Persistency Groups.
  2. Click Add to add a new group or select an existing group and click Edit.
  3. Select Use Vserver Persistence.
  4. In the Virtual Server Name box, click + to add the virtual server to the group. You can select the available virtual server or create a virtual server.
  5. Click Create if you are adding a new group or Close if you are modifying an existing group.
  6. Select the group for which you have enabled the useVserverPersistency parameter and click Edit to set a virtual server as a main to create persistence entries.
  7. From the Master vServer list, select the virtual server that has to be designated as a main virtual server.

Arguments

useVserverPersistency

Allow the virtual servers in a group to use their own persistency parameters to create persistent sessions, instead of inheriting the persistency settings from the group settings. When this parameter is enabled, persistence cannot be set on the load balancing group.

When this parameter is disabled, the group’s virtual servers inherit the persistency parameters from the group settings.

When this parameter is toggled on the load balancing group, the NetScaler appliance flushes all the corresponding persistence entries of the group and the member virtual servers.

Possible values: ENABLED, DISABLED

Default: DISABLED

Example:

set lb group lb_grp1 -useVserverPersistency ENABLED
<!--NeedCopy-->

masterVserver

Designate a virtual server as a main virtual server in its load balancing group. Once designated, only the main virtual server can create the persistent entries used by the group.

Note: This parameter can be set only if the useVserverPersistency parameter is enabled.

Example:

set lb group lb_grp1 –masterVserver vs1
<!--NeedCopy-->

Example Configuration of Sharing Persistent Sessions by Using the Command Line Interface

The virtual servers are created

add lb vs vs1 http 10.1.10.11 80 –persistence rule –rule ‘client.ip.src’

add lb vs vs2 radius 10.2.2.2 1812 –persistenceType rule –rule ‘Radius.req.avp(8).value.typecast_text_t’
<!--NeedCopy-->

The groups are created.

add lb group lb_grp1 –persistenceType NONE –useVserverPersistency ENABLED
<!--NeedCopy-->

A virtual server in a group is designated as the main virtual server.

set lb group lb_grp1 –masterVserver vs1
<!--NeedCopy-->

The virtual servers are bound to the group.

bind lb group lb_grp1 vs1
bind lb group lb_grp1 vs2
<!--NeedCopy-->

For more details, see Setting Up Basic Load Balancing and Configuring Persistence Groups.