beautypg.com

Brocade Virtual ADX Server Load Balancing Guide (Supporting ADX v03.1.00) User Manual

Page 194

background image

178

Brocade Virtual ADX Server Load Balancing Guide

53-1003247-01

Layer 7 health checks

4

HTTP

Changing HTTP keepalive method, value, and status codes
The Brocade Virtual ADX supports two kinds of HTTP health checks:

HTTP status code health checks look at the status code returned in HTTP responses to
keepalive requests.

HTTP content verification health checks look at the actual HTML contained in HTTP responses
to keepalive requests.

The default URL page for HTTP keepalive requests used in HTTP health checks is “HEAD /1.0”. You
can change the URL that the Brocade Virtual ADX requests on a real server basis.

NOTE

For HTTP content verification health checks, you might want to change the default URL page for HTTP
keepalive requests URL page, since a request for “HEAD /1.0” would not return a response
containing HTML for content verification. You can specify a GET request for a page containing text
that can be searched and verified. Refer to

“Configuring HTTP content matching lists”

on page 208

for more information.

To configure the HTTP keepalive request to send a GET request for “sales.html”, enter the following
commands.

Virtual ADX(config)#server real zip 10.96.3.251

Virtual ADX(config-rs-zip)#port http url "GET /sales.html"

Virtual ADX(config-rs-zip)#exit

Virtual ADX(config)#server virtual-name-or-ip shoosh 10.96.4.250

Virtual ADX(config-vs-shoosh)#port http

Virtual ADX(config-vs-shoosh)#bind http zip http

Virtual ADX(config-vs-shoosh)#exit

Syntax: port http url “[GET | HEAD] [/] URL-page-name

GET or HEAD is an optional parameter that specifies the request type. By default, HTTP keepalive
uses HEAD to retrieve the URL page. You can override the default and configure the Brocade Virtual
ADX to use GET to retrieve the URL page.

The slash (/) is an optional parameter. If you do not set the GET or HEAD parameter, and the slash
is not in the configured URL page, then Brocade Virtual ADX automatically inserts a slash before
retrieving the URL page.

To change the HTTP status codes that the Brocade Virtual ADX considers normal (not indicative of a
failure of the HTTP service), enter the following command.

Virtual ADX(config-rs-zip)#port http status-code 200 201 300 302

Syntax: port http status-code range [range[range[range]]]

The command in the example specifies two ranges (200–201 and 300–302). You can specify up to
four ranges (total of eight values). To specify a single message code for a range, enter the code
twice. For example to specify 200 only, enter the port http status-code 200 200 command.

NOTE

When you change the status code ranges, the defaults are removed. As a result, you must specify
all the valid ranges, even if a range also is within the default ranges. For example, if you still want
codes 200 to 299 to be valid, you must specify them.