Route Health Injection

When the web browser sends its TCP SYN request (to initiate the HTTP session with the web host), the gateway router used by the client’s computer looks in its routing table for the route to the requested IP address. The router may receive multiple paths, in which case the router typically chooses the path with the lowest cost (usually the number of router hops to the host) to place in the routing table. The paths can all go to the same host or to different hosts. In the case of globally-distributed SLB, the paths go to different hosts. The shortest path takes the client to the gateway router attached to the SLB or the directly-attached server that is closest to the client. Thus, when a client on the West coast requests the web site, the client’s gateway sends the request to the SLB in Los Angeles. A client in London would instead be directed to the directly-attached server in Paris.

The router’s behavior works well when all the real servers are available. However, suppose the real servers attached to the SLB in Los Angeles become unavailable. This results in the VIP on that SLB becoming unavailable.

In a globally-distributed SLB configuration, a client can still reach the desired VIP (web site) if the client’s gateway router receives a path to another site that contains the VIP the client is trying to reach. However, gateway routers typically advertise network routes rather than host routes. As a result, even if the VIP (web site) is unavailable, the gateway router still advertises the network to which the VIP belongs. Consequently, a client’s gateway router can still have a path to the unavailable server, in which case the client does not receive the requested web page.

By configuring the routing switches attached to the SLBs or real servers that contain the web site to check the health of the web site (HTTP application), you can ensure that the routing switches advertise paths only to for web site locations that are available:

If the web site passes the health check, the routing switch advertises a host route to the web site’s IP address.

If the web site fails the health check, the routing switch removes the host route. The route is no longer advertised and ages out of the routing tables in clients’ gateway routers.

As a result, those paths to the web site’s IP address that are no longer available age out of the routing tables on gateway routers while the paths that are still available remain in the routing tables. When a client uses its gateway router to reach the web site, the gateway's path to the site’s IP address is usually the one with the lowest cost. In Figure 17.1, when the site at Los Angeles is available, the client's gateway uses the path to Los Angeles as the route to IP address 209.157.22.249. However, if the IP address at the Los Angeles site becomes unavailable and thus fails its health check, the HP 6308M-SX routing switch at the Los Angeles site removes the static host route for 209.157.22.249 from its route table. The path on the client's gateway ages out and is replaced by the next valid path with the lowest cost, in this case the path to 209.157.22.249 at the New York site.

HTTP Health Check Algorithm

When you configure a routing switch to periodically check the health of the HTTP port on a web server, the routing switch does one of the following based on the result of the health check. The health check algorithm applies regardless of whether the web server is directly attached to the routing switch (or attached through Layer 2 switches) or is attached to an SLB that is load balancing the IP address among multiple servers.

If the health check is successful, the routing switch places a static host route in its route table for the web site’s IP address. When the routing switch sends a routing advertisement, the host route is included. The client's gateway router will receive this host route as one of the paths to the IP address.

If the health check is not successful, the routing switch removes the static host route (if present) for the IP address. As a result, the route ages out of the routing tables on other routers. After the removed route ages out of the routing table on the client's gateway router, the router accepts another path to the IP address.

You can configure a separate HTTP health check for each web site IP address. The health check consists of a standard TCP connection followed by a standard request for an HTTP page on the IP address. If the HTTP page responds with an acceptable HTTP status code, the IP address passes the health check, at which point the routing switch leaves the static host route to the IP address in the route table or adds the route if it is not present.

By default, the HTTP health check is disabled. Once you enable the health check, the routing switch sends the health check every five seconds by default. The default health check consists of a HEAD request for the default home page “1.0”. If the web site does not respond to a health check, the routing switch resends the health check up to two more times by default before determining that the web site is no longer available and removing the static host route for the web site.

All the health check parameters are configurable. See “CLI Syntax” on page 17-4.

17 - 3