Forum Discussion
Raj_57800
Nimbostratus
Apr 15, 2010Monitor using host header
I am trying to setup a monitor page using host header. It is working when when it is done manually but not when created as a monitor page. Request experts advice. Thanks
Testing through Teln...
Does the pool member respond with a 200 to a normal monitor request? Does it respond with a 200 when it sends the service unavailable message? The service unavailable message is typically sent with a 503 status code. If your app uses a 200 response for service unavailable, you could configure one monitor that makes a request and looks for "200 OK" in the response and a second "reverse" monitor which marks the pool member up if the response does not contain "service unavailable":
monitor reverse_monitor {
defaults from http
reverse
recv "service unavailable"
send "GET /monitor_page.html HTTP/1.1\r\nHost: \r\nConnection: Close\r\n"
}
monitor reverse_monitor {
defaults from http
recv "200 OK"
send "GET /monitor_page.html HTTP/1.1\r\nHost: \r\nConnection: Close\r\n"
}
If the app responds with a 503 status for service unavailable you can just use a single monitor which sends a monitor request and expects a 200 OK response back in order to mark the pool member up.
Aaron
Aaron
- May 09, 2018
This should work:
when HTTP_REQUEST { if { ([HTTP::host] eq "x.123.com") && [HTTP::uri] starts_with "/123.asp" } { set llactid [URI::query [HTTP::uri] "llactid"] if { ($llactid ne 30484) && $llactid > 29999 } { HTTP::redirect "https://y.abc.com/trackalyze.asp?r=&p=https%3A//site.com/&llactid=$llactid&llnocookies=undefined" } } }
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