Brocade ADX – Policy-Based Server Load Balancing

Policy-Based Server Load Balancing (PB-SLB) provides the ability to distribute traffic based on the source IP address of the client.

There are 2 ways in which to configure PB-SLB. You can either pull a list of IP`s from a TFTP server or define the IP`s directly on the ADX.
This example is based on defining the IP`s directly on the ADX.

Example

Within this example we will balance any traffic from a source IP of 8.8.8.8 or 9.9.9.9 to the real servers REAL3 or REAL4. All other traffic will be balanced to REAL1 or REAL2.

Assign Groups

First of all we place our real servers into groups.

server real REAL1 192.168.1.1
  port http group-id 1 1

server real REAL2 192.168.1.2
  port http group-id 1 1

server real REAL3 192.168.1.3
  port http group-id 2 2

server real REAL4 192.168.1.4
  port http group-id 2 2

Create PB-SLB Rules

Next we define our PB-SLB rules.

First of all we define which source IP`s should go to which group. We then define a default group to ensure that should none of the source IP`s match, traffic is still sent to a defined group (in this case group 1).
To ensure that the policy list is saved to flash by default when you enter a ‘wr mem’ the command ‘enable-config-gen’ is also entered.

server pbslb add 8.8.8.8 255.255.255.255 2
server pbslb add 9.9.9.9 255.255.255.255 2
server pbslb default-group-id ipv4 1
server pbslb enable-config-gen

Enable

The final step is to then enable PB-SLB on the virtual server along with binding each of the real servers that we previously assigned the group id`s to.

server virtual VIP_172.16.1.100
 port http sw-l4-pbslb
 port ssl sw-l4-pbslb
 bind http REAL1 80
 bind http REAL2 80
 bind http REAL3 80
 bind http REAL4 80

Troubleshooting

You can confirm that your real servers are being hit via the use of ‘show server sessions’. To display your PB-SLB list you can also use the command ‘show pbslb all 0’.

Note : Please take into account that persistence takes precedence over PB-SLB. Based on this should any form of persistence be configured within your Virtual Server you may not observe the expected results.

Rick Donato

Want to become a networking expert?

Here is our hand-picked selection of the best courses you can find online:
Cisco CCNA 200-301 Certification Gold Bootcamp
Complete Cyber Security Course – Network Security
Internet Security Deep Dive course
Python Pro Bootcamp
and our recommended certification practice exams:
AlphaPrep Practice Tests - Free Trial