Extension: Controlling Server Selection

Sometimes you may prefer your customers to access a certain server for certain traffic types. However, if that server fails, they still require redundancy to an alternate server.

This section shows how to configure this. The example gives you control over server selection for SFTP (Secure File Transfer Protocol) traffic, while providing server redundancy if the preferred server fails. In this example, SFTP favours the first resource only (192.168.1.1). It only uses the second resource if the first resource fails.

The load balancers use pings to monitor the health of each resource. When the primary resource fails, this triggers a script to enable the secondary resource.

To provide this solution, you need to add the following steps:

Configure Load Balancing: Extra Commands

Configure the Triggers: Extra Commands

Modify the Scripts

Create New Scripts

Configure Load Balancing: Extra Commands

This section describes the commands you need to add to step 8 on page 5 for load balancer 1 and page 8 for load balancer 2. These extra commands make load balancing act on SFTP traffic as well as web traffic.

Add a resource pool for SFTP.

add lb respool=sftp selectmethod=roundrobin faillast=no

Add both SFTP resources to the SFTP resource pool. Note that SFTP is FTP encapsulated by SSHv2 on port 22.

add lb resource=sftp1 ip=192.168.1.1 port=22 respool=sftp

add lb resource=sftp2 ip=192.168.1.2 port=22 respool=sftp

Disable SFTP2. This forces the load balancer to use SFTP1, which is the desired behaviour because SFTP1 is the preferred server. Later in this configuration, we will create a trigger so that the load balancer changes to SFTP2 if SFTP1 goes down.

disable lb resource=sftp2 immediately

Add and enable the Virtual Balancer for SFTP traffic.

add lb virtualbalancer=sftp publicip=172.214.1.2 publicport=22 respool=sftp affinity=no

enable lb virtualbalancer=sftp

Note that affinity is turned off. If resource 1 fails, this stops new connections from automatically trying to use the failed resource.

Configure Load Balancer Redundancy on Allied Telesis Routers and Switches

10

Page 10
Image 10
Allied Telesis Routers and Switches manual Extension Controlling Server Selection, Configure Load Balancing Extra Commands