Monitoring HTTP servers
Previous Topic  Top  next topic

When polling the status of an HTTP server, the following steps are taken:

A TCP connection is established with the server IP address on port 80 (*).
An HTTP request is sent to the server.
If a HTTP response with status code 200
(*) is received, then the HTTP server is considered functional.
With any other status code, the server is considered non-functional.
The TCP connection is closed.

In step 2, Simple Failover uses the HTTP HEAD
method instead of the more common GET and POST methods.
HEAD works the same as GET, except the web-server will only return the HTTP headers and not the entire web-page.
Simple Failover only needs to see the header, so using the HEAD method significantly reduces the amount of data needed to be transferred.

Also in step 2, a Host
header with the Server Set domain name is included in the HTTP request.
This means that Simple Failover can also be used with web-servers utilizing "name based virtual hosting" (multiple web-sites for different domain names on a single IP address).
Modern web-browsers also include this Host
header in all HTTP requests.

While performing above steps, Simple Failover may also encounter a communications error (winsock error), or that the TCP connection is unexpectedly closed by the remote server, or it may time out waiting for the TCP connection to be established or a response to be received.
In any of these cases, the server is considered non-functional.

For details on the HTTP protocol, please see RFC1945.
This and other RFCs can be obtained from http://www.rfc-editor.org/rfcsearch.html
.

(*) Alternate port number can be specified in the Port field. Alternate status codes can be specified in the Advanced Server Set Properties dialog.