ADC

Traffic distribution in multiple routes based on five tuples information

In a load balancing setup, a NetScaler appliance can have multiple routes to send a packet to its destination. For example: to a server, and to a client.

A NetScaler appliance uses a hashing algorithm to select a route for sending the packet to its destination.

The hashing algorithm uses the following two tuples of a packet to calculate a hash, based on which the NetScaler appliance selects a route for the packet.

  • Source IP address
  • Destination IP address

The selection of routes based on two tuples information can cause an uneven distribution of traffic on the available routes. This uneven distribution of traffic leads to overloading of traffic in some routes.

To resolve this issue, from build 13.0 71.x, the NetScaler appliance uses the following five tuples information of a packet in the hashing algorithm to select a route for the packet:

  • Source IP address (Client IP)
  • Source Port (Client Port)
  • Destination IP address(Service IP)
  • Destination Port (Service Port)
  • Protocol number

The selection of routes based on five tuples information ensures even distribution of traffic on the available routes. This even distribution of traffic prevents overloading of traffic in a route.

Consider an example of a load balancing setup where a client sends a request to the VIP address. The NetScaler appliance uses the following five tuples information to select a route to send the request packet to the load balanced server:

  • Source IP address (Client IP address)
  • Source Port (Client port)
  • Destination IP address (Service IP address)
  • Destination Port (Service port number)
  • Protocol Number

If use source IP (USIP) mode is enabled, then all five tuples are considered as the input of hash to select a route. If use subnet IP (USNIP) mode is enabled, both SNIP and Source Port are not considered as the input because they are selected after route selection. For information on how to configure USIP and USNIP mode, see Enable Use Source IP Mode and Configuring Subnet IP Addresses (SNIPs).

Note:

From build 13.1 30.x, the NetScaler appliance uses the five tuples hashing algorithm instead of the two tuples hashing algorithm to select a route for load balancing monitor probes.

Precedence regarding other route selection based NetScaler features

This section talks about the precedence of the route selection based on five tuples feature and other route selection related features in a NetScaler appliance.

  • Policy Based Routes (PBR). PBR rules always take precedence over route selection based on five tuples.

  • Mac Based Forwarding (MBF). In a load balancing configuration, MBF or route selection based on five tuples takes precedence in the following cases:

    • For a client initiated traffic to the VIP address of the load balancing configuration in the NetScaler appliance:
      • Request traffic destined to a load balanced server. Route selection based on five tuples takes preference over MBF.
      • Response Traffic destined to the client. MBF takes preference over route selection based on five tuples.
    • For a server initiated traffic to the SNIP address in the NetScaler appliance:
      • Response Traffic destined to the client. Route selection based on five tuples takes preference over MBF.
      • Request traffic destined to a load balanced server. MBF takes preference over route selection based on five tuples.
Traffic distribution in multiple routes based on five tuples information