FTP Load Balancing

This chapter describes how to configure SLB for FTP services.

Overview

FTP load balancing optimizes the download experience for clients by balancing FTP traffic across servers in a server farm. You can provide clients with a single, published virtual IP address for large files, and serve the files from a set of real servers.

FIGURE 51    shows an example of an FTP load balancing solution.

FIGURE 51         FTP Load Balancing

FTP-LB.jpg

 

In this example, FTP files are served by three real servers. Each server has the same set of files available for download. One of the servers also provides the HTML pages for the download site.

ACOS devices support both the passive and active (port) FTP modes.

The following example uses the weighted-round-robin load balancing method. The ACOS device is configured to send all HTTP requests to server ftp-2. FTP requests will be load balanced among servers ftp-2, ftp-3, and ftp-4.

By assigning a weight to a real server and using a weighted load-balancing metric, you can bias load-balancing decisions to favor that server. This example assumes that the servers have equivalent capacity and performance. The differing weights compensate for the greater load to be placed on the server that is handling the HTTP requests. 

Service Groups

This example uses two service groups. One service group contains all three FTP servers and the other service group contains a single server for HTTP. To provide the weighted load balancing described above, the load balancing method is changed from the default (round robin) to weighted round robin for the FTP service group.

Templates

In this example, two TCP templates are required.

     For HTTP, the default TCP template is used. You do not need to explicitly bind this template to the HTTP port on the virtual server. ACOS automatically binds this template to a virtual TCP port on a virtual server when you create the port, unless you explicitly bind another TCP template to the virtual port instead.

     For FTP, a custom TCP template is required, with the idle time set to a high value, to prevent FTP download sessions from timing out if they pause for a while. This custom TCP template must be explicitly bound to the virtual FTP port on the virtual server. In this case, the custom template is used instead of the default TCP template.

The default HTTP template is assigned to the virtual HTTP port by default. However, the parameters in the default HTTP tem­plate are unset by default. For this configuration, you do not need to configure a different HTTP template or change settings in the default one.

This example does not include configuration of server or port templates, so the default templates and their settings are applied.

For more information server and port templates, see templates, see Server and Port Templates.

Health Monitors

This example uses the following health monitors to check the real servers:

     Ping – Tests Layer 3 connectivity to the servers.

     HTTP – Tests the HTTP port by requesting a Web page from the port. In this example, the default settings are used: Every 30 seconds, the ACOS device sends an HTTP Get request for the index.html page.

     FTP – Tests the FTP port by sending a login request to the port. In this example, the default settings are used: Every 30 seconds, the ACOS device sends an anonymous FTP login request to port 21.

The Ping health monitor is already configured by default, and is enabled by default when you add the real server.

The HTTP and FTP monitors must be configured and applied to the real server ports.

ACOS has default Layer 4 health checks it uses to test the TCP and UDP transport layers. This configuration also uses those health checks. (For information, see Default Health Checks.)

Configuring FTP Load Balancing

To configure FTP load balancing:

1.     Configure HTTP and FTP health methods, to use for checking the health of the HTTP and FTP ports on the servers.

2.     Configure the real servers:

a.     For each server, add its FTP port and enable health checking of the port, using the FTP health method configured in step 1.

b.     For the server that will serve the Web pages, add the server’s HTTP port and enable health checking of the port, using the HTTP health method configured in step 1.

c.     Assign weight 80 to the HTTP/FTP server. Assign weight 100 to each of the FTP servers that will not also be handling HTTP. These weights will cause the ACOS device to select the HTTP/FTP server for FTP only 80% as often as each of the other servers.

3.     Configure a TCP template and set the idle time in the template to a high value.

4.     Configure a service group for HTTP and add the HTTP server to it.

5.     Configure another service group for FTP and add the FTP servers to it.

6.     Configure the virtual server:

a.     Add TCP ports for HTTP and FTP.

b.     Bind the HTTP port to the HTTP service group.

c.     Bind the FTP port to the FTP service group and to the TCP template.

Using the GUI

To configure the health monitors

1.     Select ADC > Health Monitors.

2.     Click Create.

3.     In the Name field, enter a name for the monitor.

4.     Click Method Type drop-down menu and select HTTP.

5.     Click Create Monitor. The new health monitor appears in the health monitor table.

6.     Repeat step 2 through step 5 to configure the FTP health monitor. In step 4 select FTP instead of HTTP.

FIGURE 52         ADC > Health Monitors > Create (HTTP)

4.0_ADC-healthmonitor-HTTP-create.png

 

FIGURE 53         ADC > Health Monitors > Create (FTP)

4.0_ADC-healthmonitor-FTP-create.png

 

 

FIGURE 54         ADC > Health Monitors (showing configured health monitors)

4.0_ADC-healthmonitor-list.jpg

 

To configure the real servers

1.     Select ADC > SLB.

2.     Select the Servers tab from the menu bar.

3.     Click Create.

4.     Enter a name for the server in the Name field.

5.     Select the Type radio button (IPv4, IPv6, FQDN).

6.     Enter the IP address of the server in the Host field.

To configure the wight of the real servers

1.     Still from within the Create Server page, click Advanced Fields to display additional configuration options.

2.     In this example, change the value in the Weight field to 80.

3.     In the Port section, click Create

4.     In the Port Number field, enter the number corresponding to HTTP (or FTP).

5.     Leave the Protocol set to TCP.

6.     In the Health Check radio button, click the Monitor radio button, and from the Health Monitor drop-down menu that appears, select the HTTP or FTP health monitor you just configured. (Select the appropriate health monitor that matches the port type you configured, either HTTP or FTP.)

7.     Click Create. The new port appears in the port list.

Repeat the process to configure the real servers and the weight of the real servers for each of the other real servers you wish to add.

FIGURE 55         ADC > SLB > Server > Create (ftp-2)

4.0_ADC-SLB-Server-ftp2.png

 

FIGURE 56         ADC > SLB > Server > Port (ftp-2)

4.0_ADC-SLB-Server-port-ftp2.png

 

FIGURE 57         ADC > SLB > Server (ftp-2 with both http and ftp ports added)

ADC-SLB-Server-portadded-ftp2.png

 

FIGURE 58         ADC > SLB > Server (showing configured real servers)

ADC-SLB-Server-ftp2-list.png

 

NOTE:                               The Health Monitor column shows the Layer 3 (ICMP ping) health monitors for the real servers, not the Layer4-7 health monitors for individual server ports. Click on + to view the ports associated with the server.

To configure the TCP template for FTP

1.     Select ADC > Templates.

2.     Select the L4 Protocols tab from the menu bar at the top of the page.

3.     Click Create and select TCP from the drop-down menu.

4.     Enter a name for the template in the Name field.

5.     In the Idle Timeout field, enter 15000.

6.     Click OK. The new template appears in the SLB template table.

 

To configure a service group for HTTP

1.     Select ADC > SLB.

2.     Select the Service Groups tab from the menu bar at the top of the page.

3.     Click Create.

4.     Enter a name in the Name field.

5.     Leave the transport Protocol set to TCP.

6.     In the Algorithm field, select the load balancing method. For this example, select Weighted Round Robin.

To configure a service group member for HTTP

1.     While still in the Create Service Group page, from the Member section, click the Create button to add a member to this service group.

2.     In the Choose Creation Type area, select the appropriate radio button (Existing Server or New Server).

     If adding an existing server to this service group, select the Server drop-down and select the existing server.

     If adding a new server to this service group, enter the real server’s name and IP address.

3.     Enter the port number for this protocol in the Port field.

4.     Click Create. The server and port appear in the member list.

5.     Click Update to update this service group. The new service group appears in the service group table.

Repeat this process of adding a service group and service group member for each combination of server and port. The fol­lowing example shows adding member 10.10.10.2 for port 80 to service group http-grp.

FIGURE 59         ADC > SLB > Service Group (for HTTP)

ADC-SLB-Servicegroup-http.png

 

FIGURE 60         ADC > SLB > Service Group (for HTTP) Member Add

ADC-SLB-Servicegroup-http-addmember.png

To configure a service group for FTP

Repeat the procedure in To configure a service group for HTTP, with the following differences:

     In the Algorithm drop-down list, select Weighted Round Robin. (If your configuration does not use weights to bias server selection, you can leave this field set to Round Robin.)

     The following example shows adding members 10.10.10.2-4 for port 21.

FIGURE 61         ADC > SLB > Service Group (for FTP)

ADC-SLB-Servicegroup-ftp-3.png

 

FIGURE 62         ADC > SLB > Service Group (service groups added)

ADC-SLB-Servicegroup-ftplist-httplist.png

 

To configure the virtual server

1.     Select ADC > SLB

2.     Select Virtual Servers from the menu bar at the top of the page, if not already selected.

3.     Click Create.

4.     Enter a name in the Name field.

5.     Enter the virtual IP address in the IP Address field. This is the IP address to which clients will send HTTP and FTP requests.

To configure the virtual server port

1.     While still in the Create Virtual Server page, In the Virtual Port section, click Create. The Virtual Server Port section appears.

2.     Enter a name in the Name field. This is optional.

3.     In the Protocol drop-down list, select the service type.

In this example, there are two services, HTTP and FTP. Select HTTP first and go to the next step.

4.     Edit the number in the Port field to match the protocol port that clients will request at the virtual IP address.

5.     Select the service group that you configured in To configure a service group for HTTP from the Service Group drop-down list.

6.     Click Create. The port and service group appear in the virtual port list.

7.     Repeat this process to configure the virtual server port for the FTP service.

The following example shows creating the virtual server, creating the virtual port, and assigning the service group.s

FIGURE 63         ADC > SLB > Virtual Server > Create

ADC-SLB-Virtual_Server-Create.png

 

FIGURE 64         ADC > SLB > Virtual Server - Virtual Server Port section (for HTTP)

ADC-SLB-Virtual_Server-virtualport-http.png

 

FIGURE 65         ADC > SLB > Virtual Server - Virtual Server Port section (for FTP)

ADC-SLB-Virtual_Server-virtualport-ftp.png

 

FIGURE 66         ADC > SLB > Virtual Server - Port section (ports added)

ADC-SLB-Virtual_Server-virtualport-added.png

 

FIGURE 67         ADC > SLB > Virtual Server (virtual server added)

ADC-SLB-Virtual_Server-list.png

 

 

Using the CLI

The following commands configure the HTTP and FTP health monitors:

ACOS(config)#health monitor http-monitor

ACOS(config-health:monitor)#method http

ACOS(config-health:monitor)#exit

ACOS(config)#health monitor ftp-monitor

ACOS(config-health:monitor)#method ftp

ACOS(config-health:monitor)#exit

The following commands configure the real servers:

ACOS(config)#slb server ftp-2 10.10.10.2

ACOS(config-real server)#weight 80

ACOS(config-real server)#port 80 tcp

ACOS(config-real server-node port)#health-check http-monitor

ACOS(config-real server-node port)#exit

ACOS(config-real server)#port 21 tcp

ACOS(config-real server-node port)#health-check ftp-monitor

ACOS(config-real server-node port)#exit

ACOS(config-real server)#exit

ACOS(config)#slb server ftp-3 10.10.10.3

ACOS(config-real server)#weight 100

ACOS(config-real server)#port 21 tcp

ACOS(config-real server-node port)#health-check ftp-monitor

ACOS(config-real server-node port)#exit

ACOS(config-real server)#exit

ACOS(config)#slb server ftp-4 10.10.10.4

ACOS(config-real server)#weight 100

ACOS(config-real server)#port 21 tcp

ACOS(config-real server-node port)#health-check ftp-monitor

ACOS(config-real server-node port)#exit

ACOS(config-real server)#exit

The following commands configure the TCP template for use with FTP:

ACOS(config)#slb template tcp ftp-longidletime

ACOS(config-L4 TCP LB template)#idle-timeout 15000

ACOS(config-L4 TCP LB template)#exit

The following commands configure the service group for HTTP:

ACOS(config)#slb service-group http-grp tcp

ACOS(config-slb service group)#member ftp-2 80

ACOS(config-slb service group-member:80)#exit

ACOS(config-slb service group)#exit

The following commands configure the service group for FTP:

ACOS(config)#slb service-group ftp-grp tcp

ACOS(config-slb service group)#member ftp-2 21

ACOS(config-slb service group-member:21)#member ftp-3 21

ACOS(config-slb service group-member:21)#member ftp-4 21

ACOS(config-slb service group-member:21)#method weighted-rr

ACOS(config-slb service group)#exit

The following commands configure the virtual server:

ACOS(config)#slb virtual-server ftp-vip 192.168.10.21

ACOS(config-slb vserver)#port 80 http

ACOS(config-slb vserver-vport)#service-group http-grp

ACOS(config-slb vserver-vport)#exit

ACOS(config-slb vserver)#port 21 ftp

ACOS(config-slb vserver-vport)#service-group ftp-grp

ACOS(config-slb vserver-vport)#template tcp ftp-longidletime

 

 

Table of Contents

Index

Glossary

-Search-

Back