Forum Discussion
Gregt_33960
Nimbostratus
Nov 12, 2008Health Check Question
Hello,
I have my F5 managing several pools and subsequent websites. As part of each pool I have set up a HTTP health check to the pools. As I understand the LTM test it simply does a HTTP GET to the specified port number defined for each pool. The polling interval is default.
The issue is that my WebSphere logs show massive number of connections/sessions. I believe it is the F5 that when it performs a HTTP GET it is creating a new session but not terminating it.
My question to the forum is that when the LTM performs the HTTP GET, does it actualy initiate a session and then more importantly how do I get it to terminate the session?
thanks
Greg
8 Replies
- hoolio
Cirrostratus
Hi Greg,
You can have the BIG-IP tell the server that the server close the TCP connection using an HTTP 1.1 formatted send string with a Connection header:
GET /monitor_page.html HTTP/1.1\r\nHost: \r\nConnection: Close\r\n
Sessions would be created on the application--not LTM. If you want to tell the server that the session should be removed, you'd need to figure out how the client can do that in an HTTP request and then configure that in the SEND string. If it requires two requests (one to create the session and one to close it) you could create an external monitor which references a shell script to make the two requests. You can find some examples for external monitors in the Monitoring Codeshare (Click here). Else, is there a page which LTM could monitor for which the server won't generate a session? That might be easier than trying to end the session.
Aaron - Gregt_33960
Nimbostratus
Aaron,
Thank you for the information. My apologies on the delayed response. In reading your response, it looks like there are two possible options. One would be to create my own custom monitor on the LTM or the second to find or write an external script. If I might pursue the first, since all I want is a simple get and then terminate the session can ask a few more questions then?
My LTM currentl manages about 10 pools each with their own application environment.. basically each environment has a unique port.For each pool I am doing an HTTP health test.
1) Does that mean, on the LTM I would have create a custom HTTP health monitor for each pool?
2) Do you happen to know of any sample snippets of something similar I could use for reference? Iask because when I look at the snippet you provided I am not sure if that is the exact string? or do I substitute a real HTML page, host, connection port into that string?
thanks
Greg
thanks
Greg - hoolio
Cirrostratus
Hi Greg,
Most webservers will respond to a request with an HTTP host header and no value. The Connection: close header tells the server that the client won't try to re-use the TCP connection, so the server can close the connection after responding to the request.
Rather than worrying about the monitor configuration, I'd focus first on finding a page you can make a request to where the server doesn't generate a session. If that's possible, you could use a standard HTTP monitor with a customized send string. If that's not possible, then you could figure out how to make a request which tells the server to kill the session. That would probably take two requests and require using an external monitor which references a shell script using curl. There are examples of using curl from a shell script for an external monitor in the monitoring Codeshare (Click here).
Aaron - zafer
Nimbostratus
Hi aaraon
is that possible use http monitor for text content
for example i want send request GET /id/123445 and receive string hello
but hello content in the text file not html
this is not working with this way
i also use this method getting response from html content
is that possible work from text file
regards
zafer - hoolio
Cirrostratus
Hi zafer,
The monitoring daemon evaluates the receive string against the response content. So it shouldn't matter what type of file you configure for the request as long as the server responds with the expected content.
If this isn't working, you could either enable bigd debug (b db bigd.debug enable) and check the /var/log/bigdlog file, or you could test from the command line using curl. If you make a curl request from LTM to a pool member, do you get back a response containing "hello"? You can use something like 'curl -v http://1.1.1.1/id/123445' to test where 1.1.1.1 is the pool member IP address.
Aaron - Gregt_33960
Nimbostratus
Aaron,
I am truly appreciative of your assistance on this issue and I feel bad about my lack of knowledge on these types of resolutions. I confess I am not an HTTP guru and recently inherited the F5 management so I will apologize if these questions are remedial. I have been re-reading your responses and I think I understand but I need to delve a little deeper to understand. I am providing more information on my environment in hopes to better understand your suggestions.
My configuration as such is that I have 4 physical web servers running multiple application environments on each server via a unique port number. I have created a pool for each application environment as dictated specify the unique port number for that pool. For example, I have a test environment running on port 80 and a training environment running on port 8080 with Websphere as my App/Web server.
train_pool conains webserver1 & webserver2 port 8080
test_pool contains webserver3 & webserver4 --port 80
When creating the pool I use the default Health Check to test if Webserver is available. I also have standard log in Page for each environment and use IRULES for URI filter.. for example
www.domain.com/train/jsp/pgLogin.jsp (which is directed to train_pool and port)
www.domain.com/test/jsp/pgLogin.jsp (which is directed to test_pool and port)
With this default configuration, I know the F5 performs an HTTP GET as its health check for the pool, and I assume for each physical server in the pool. This health check seems to create a session but not terminate it.. I know on the F5 you can create custom HTTP, as you indicated. What I did not understand was that there is some HTTP GET string I can create for Send strings that would be able to HTTP GET and then terminate/close the session. Is that correct? Do I put a custom receive string?I am not sure I understand the recieve string section and trying to find the Syntax... Below is a sample string I was thinking for say the train environment
GET /train HTTP/1.1\r\nHost: \r\nConnection: Close\r\n
Is this all I need with no receive string? I am assuming that the "Host" and "Connection" pieces are populated automatically via the F5 request. is it possible you can shed a little more light
thank you for help
Greg - zafer
Nimbostratus
Hi Aaron,
when i request the webpage from browser it works i think browser converting text to html
but when i use curl request the page i see 500 internal server error
what can i do monitor from flat file
zafer - zafer
Nimbostratus
Hi Aaron
i think problem is the ISS, it only accepts get request from IE and Mozilla
ISS works between client and webserver for protect from attacks
regards
zafer
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects
