Forum Discussion
SeanW_82915
Nimbostratus
Jun 23, 2009HTTP Monitor and checking http headers
I'm monitoring several web servers and wanted to come up with a health monitor that just checks the HTTP response code. I needed two... One that accepts 200/301/302 and one that also accepts an authorization request. It took a bit of head scratching, a call to TAC, and a lot of experimentation, but if you do a standard HTTP test with:
Send String: GET / HTTP/1.0\r\nConnection: Close
Receive String: HTTP/1.. (301|200|302)
It works correctly.
For the one that also accepts a 401 the receive string becomes HTTP/1.. (301|200|302|401)
SOL3224 was somewhat misleading in that it tells you to look at the redirected page if you want to check this, but there's nothing saying the two are on the same server. With the above you can put the Location header in your receive string, or just look for the 301/302.
Sean
- hoolio
Cirrostratus
Hi Sean,
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