Introduction to ServerIron ADX Application Switching and Load Balancing Module 5: Server Load Balancing (SLB) Revision 0310
Objectives Upon completion of this module the student will be able to: Describe Source-NAT Describe Hot Standby Redundancy Define Direct Server Return (DSR) Define Active Standby Redundancy Define Remote Servers Describe Primary and Backups 2
Source-NAT
The Problem: ServerIron ADX in a Multinetted Network Without Source-NAT 4
The Solution: ServerIron ADX in a Multinetted Network With Source-NAT ServerIron ADX can operate in a multinetted environment 5
Source-NAT Example Source NAT configured on a per real server basis (local) Source NAT under individual real server s is recommended server source-nat server source-ip 10.10.10.50 255.255.255.0 10.1.1.1! server real rs1 10.10.10.201 source-nat port http port http url HEAD /! server real rs2 10.10.10.202 source-nat port http port http url HEAD /! server virtual vip 169.144.10.100 port http bind http rs1 http rs2 http bind http rs4 http Use Source-NAT to reach these servers Source NAT can be configured on a global level 6
Source-NAT Lab 5-1
Lab 5-1:Source NAT 8
Lab 5-1 Review: Source-NAT Packet Walk 9
Hot-Standby Redundancy
Hot-Standby Redundancy (1 of 3) Dedicated Synchronization Link State tables are synchronized through this link without using bandwidth on the data path Detects failure of the Active switch within 1 sec In the event of a Sync Link failure, the data path is checked to see if the Active switch is still online Requires a common Layer 2 Domain: Switches & Real Servers Traffic is heard by both Switches Active Switch switches traffic from clients to the appropriate Physical Servers Standby Switch also builds Network Address Translation (NAT) table, but passes no traffic while in Standby-mode Both Switches are configured with the same MAC address (One or the other switch s lowest MAC) When the Standby takes over, no re-arp is needed Client community still uses mapping of Virtual IP to locally administered MAC address being advertised 11
Hot-Standby Redundancy (2 of 3) When an Active Switch fails Standby switch listens through sync link to detect when the other side is no longer alive Session information is kept in sync until the Active fails to communicate with the Standby Data path is also checked (via ping) to see if it was merely a failure in the Sync link Standby switch becomes Active Client to server connections are preserved across the Active to Standby failover Any lost packet retries are re-initiated by the client/server No re-arping is required by clients or downstream routers Both switches are configured with the same Locally Administered Address (LAA) MAC e.g. 02-00-0c-76-d8-88 During the failure, the Standby switch now operates as the Active switch and switches traffic 12
Hot-Standby Redundancy (3 of 3) The failed switch can be swapped out and replaced while server farm is operational The new switch takes the Standby role upon detection of the Active switch 13
Hot-Standby Redundancy Configuration On both ADX s: ADX(config)# server backup ethernet 1 00e0.5202.85ae ADX(config-vlan-22)# no spanning-tree This is the port that the heart beat cable is connected to. This is a MAC address of port one on one of the ServerIron ADXs. Enter this SAME MAC address on both ServerIron ADXs. Use the command show interface brief to display the MAC addresses. ADX(config)# server backup-preference 5 The ServerIron ADX with this command will always be the active ServerIron ADX. The 5 is the time it will take for the this ServerIron ADX to become active again in minutes, 5 is the minimum value. 14
Synchronization of Configurations Configuration ServerIron ADX A: ServerIron ADXA# configure terminal ServerIron ADXA(config)# config-sync sender e 1 mac 00e0.5201.0c72 vlan 22 Configuration ServerIron ADX B: ServerIron ADXB# configure terminal ServerIron ADXB(config)# config-sync receiver e 1 mac 00e0.5202.020a vlan 22 Initiating and and Ending the Synchronization: ServerIron ADXA(config)# confic-sync slb 15
Hot-Standby Redundancy Lab 5-2
Lab 5-2: Hot-Standby Redundancy 17
Direct Server Return (DSR)
Direct Server Return (DSR) Overview Responses from the Real Servers are sent directly back to clients via the router Optimal for high-bandwidth, low latency SLB applications Traffic Flow: a. Small requests are sent from client to the Server Farm (typically 64-128 byte) b. The small requests can result in large frames being sent directly back to the client Large GIF/JPEG images Large File transfers Maximize the throughput back to the users 19
DSR Configuration 20
DSR in Action 21
Direct Server Return (DSR) Lab 5-3
Lab 5-3: Direct Server Return (DSR) 23
Lab 5-3 Review: DSR Packet Walk 24
Active-Standby Redundancy
Symmetric Server Load Balancing Active-Standby Dual ADXs share active loads Both ADXs are Active and continue to be a backup for each other in case the other fails Supports more connections, more throughput Same application/port cannot be mapped to 2 or more VIPs If necessary create an alias port 26
Active-Standby SLB Steps to configure VIP 1 and VIP 2 on both ADX-A and ADX-B server virtual vip1 169.144.10.100 server virtual vip2 169.144.10.200 port http port http bind http RS1 http RS2 http bind http RS1 2000 RS2 2000 no port http translate 27
Active-Standby Redundancy Lab 5-4
Lab 5-4: Active-Standby Redundancy 29
Remote Server
Remote Server Farms Remote Server Farms can be: on a different subnet located in a different facility (disaster recovery) used as BACKUP of last resort (i.e. used only if all of the Local Servers are unavailable) specify Source-NAT so the traffic back to the client appears to have returned from the VIP cannot configure DSR on a remote server 31
Remote Server Lab 5-5
Lab 5-5:Remote Server 33
Other Features
Active-Active Symmetric Server Load Balancing 35
Primary and Backup Servers Primary/Backup Local or Remote Servers that are locally attached to the ServerIron ADX (not separated by one or more router hops) are local servers. 36
Primary/Backup Server Configuration Example ServerIron ADX(config)# server real-name R1 10.10.10.201 ServerIron ADX(config-rs-R1)# port http ServerIron ADX(config-rs-R1)# exit ServerIron ADX(config)# server remote-name R4 198.10.10.40 ServerIron ADX(config-rs-R4)# port http ServerIron ADX(config-rs-R4)# exit ServerIron ADX(config)# server real-name R3 10.10.10.203 ServerIron ADX(config-rs-R3)# backup ServerIron ADX(config-rs-R3)# port http ServerIron ADX(config-rs-R3)# exit ServerIron ADX(config)# server remote-name R5 198.10.10.50 ServerIron ADX(config-rs-R5)# backup ServerIron ADX(config-rs-R5)# port http Primary Servers Backup Servers ServerIron ADX(config-rs-R5)# server virtual-name VIP1 198.10.10.100 ServerIron ADX(config-vs-VIP1)# port http lb-pri-servers ServerIron ADX(config-vs-VIP1)# bind http R2 http R3 http R4 http R5 http VIP 37
Clone Real Server Configuration Auto binding of cloned server to VIP ServerIron ADX(config)# server real RS1 1.2.3.4 ServerIron ADX(config-rs-rs1)# clone-server RS2 5.6.7.8 38
Session Persistence: Sticky vs. Concurrent 39
End of Module 5: Server Load Balancing Revision 0310