Brocade Virtual ADX Server Load Balancing Guide (Supporting ADX v03.1.00) User Manual
Page 268
![background image](/manuals/361724/268/background.png)
252
Brocade Virtual ADX Server Load Balancing Guide
53-1003247-01
Layer 7 content switching
5
The hash-to--bucket persist method is illustrated in the following figure.
FIGURE 29
Hash-to-bucket persist method
For a given rule, you can configure a primary persist action and a secondary persist action. If the
primary persist action does not return a valid persist string, or if the server indicated by the primary
persist string is not available, the Brocade Virtual ADX uses the secondary persist action to direct
packets to a server.
The following commands configure a CSW rule and policy that use the persist action.
Virtual ADX(config)#csw-rule r1 header host exists
Virtual ADX(config)#csw-policy p1
Virtual ADX(config-csw-p1)#match r1 persist offset 0 length 0
In the above example, the csw-rule command creates a rule that matches if an incoming packet
contains an HTTP host header field. The csw-policy command creates a policy called p1. The match
r1 persist command associates the rule with the persist action. As a result, if an incoming packet
has an HTTP host header field, the contents of the host header field are used as the persist string.
The Brocade Virtual ADX uses the persist string along with the default hashing-bucket persist
method to calculate the real server to which to send the packet.
Syntax: [no] match rule-name persist offset offset length length [[persist-method] [secondary]]
or
Syntax: [no] match rule-name persist offset offset terminator string [[persist-method] [secondary]]
The offset variable specifies the offset in bytes from the end of the matched string, matched by the
rule-name to be used as the persist string. If you specify 0 as the offset, the persist string begins
right after the matched string.
The length variable specifies the length in bytes of the persist string. If you specify 0 as the length,
the persist string ends at the end of the matched content.
The string variable specifies the substring with which the persist string ends.