Forum Discussion
irule http_response F5 error page should not intercept server response for one of uri (LTM 10.2.4)
Hello Team,
I have single irule which contains multiple hostname & uri to direct request to respective pool and have F5 http response error page like below. Now, i received request that to one of the uri (example start with /platform) should bypass below F5 error http response and process only only original server response.
Current below response rule : when HTTP_RESPONSE { if {([HTTP::status] starts_with "5")} { HTTP::respond 500 content [b64decode [class element -value 0 ckid_error_500.html]] "Content-Type" "text/html" } }
Please help me to get the irule for uri "/platform" should bypass above F5 response and only response original server response.
2 Replies
- Vijay_E
Cirrus
Try this:
when HTTP_RESPONSE { if { ([HTTP::status] starts_with "5") and (not([HTTP::header values Location] contains "/platform")) } { HTTP::respond 500 content [b64decode [class element -value 0 ckid_error_500.html]] "Content-Type" "text/html" } } Hi Nityanand,
to use request-only informations in your response events, you could simply store the required informations into variables during one of the request events and then use the stored information during response events to perform certain checks...
when HTTP_REQUEST { set path [HTTP::path] } when HTTP_REQUEST { if { ( [HTTP::status] starts_with "5" ) and not ( [string tolower $low_path] starts_with "/platform") } then { HTTP::respond 500 content [b64decode [class element -value 0 ckid_error_500.html]] "Content-Type" "text/html" } }Cheers, Kai
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* 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