Napatech

Napatech

Hash Key Generation

Often, network applications need to look at flows of frames that are transmitted between specific devices (identified by their IP addresses) or even between applications on specific devices (identified i.e. by protocol and UDP/TCP/SCTP port numbers used by the application).

Napatech Network Adapters support identification of such flows by calculating a hash key value for each frame. Below are 3 examples of some of Napatech's 17 hash keys:
  • 2-tuple Hash Keys: The 2-tuple hash key is used to identify frame flows between two devices, as it is calculated on the basis of the source and destination IP addresses (only available on the NT Family Adapters).
  • 5-tuple Hash Keys: The 5-tuple hash key is used to identify frame flows between two applications, as it is calculated on the basis of both the source and destination IP addresses, and the source and destination UDP/TCP/SCTP port numbers, and the IP protocol field.
  • GTP Hash Keys: The GTP hash key is used to identify mobile conversation flows. It is calculated on the basis of both the source and destination IP adresses, and the GTP flow label (for GTPv0) or the GTP TEID (for GTPv1/v2).

The hash key generation has the following common properties:
  • All hash keys are calculated using the CRC32 checksum algorithm.
  • Hash keys can be calculated to identify unidirectional flows. In this case a flow from A to B and a flow from B to A will generate different hash key values.
  • Hash keys can be calculated to identify bidirectional flows. In this case a flow from A to B and a flow from B to A will generate the same hash key values. This method will often provide the best host CPU performance when processing/tracking sessions, due to a higher CPU cache hit rate.
  • Using hash keys is an efficient method to distribute captured frames to multiple CPU cores in the host server. The use of hash keys can significantly increase the cache hit performance of many network applications running in multi-CPU systems, as the flow context for the frames is readily available for the individual CPU cores most of the time.

In Napatech NT Family Network Adapters, the hash keys can be used to balance the frame load in multi-CPU systems, as the adapter distributes the frames evenly between a number of CPU cores, according to the hash key value range.

The hash key value is provided to the server application in the Extended Descriptor for each frame.
 
The type of hash key to be generated can be selected dynamically for each frame based on the frame protocol information. The hash key type is delivered in the Extended Descriptor.

Additional Information

Highlights:
  • 17 hash keys
  • Unidirectional and bidirectional flows
  • High server cache performance for most applications

See Also:

© Napatech A/S, all rights reserved. Terms & Conditions