Forum Discussion
GavinW_29074
Nimbostratus
Feb 07, 2012HTTP_RESPONSE not firing
Hi there,
I'm using the ProxyPass v10 iRule to perform some path rewriting on some of our VIP's...
However we seem to be getting some sporadic issues whereby the HTTP_RESPONSE ev...
GavinW_29074
Nimbostratus
Feb 15, 2012Ah hah... Found it...
This rule was causing the errors...
when RULE_INIT {
set static::ErrorDebug 1
}
when HTTP_REQUEST priority 50 {
if {$static::ErrorDebug == 1} { log local0. "CatchErrors HTTP Request at Priority 50:" }
Record request details encase needed later.
set HTTP_HOST [HTTP::host]
set HTTP_URI [HTTP::uri]
set HTTP_METHOD [HTTP::method]
set VSPool [LB::server pool]
if {$static::ErrorDebug == 1} { log local0. "\$HTTP_HOST = $HTTP_HOST, \$HTTP_URI = $HTTP_URI, \$HTTP_METHOD = $HTTP_METHOD, \$VSPool = $VSPool" }
if { [active_members $VSPool] < 1 } {
LB::detach
log local0. "Client [IP::client_addr] requested [HTTP::host][HTTP::uri] no active nodes available."
No pool members available. Setting error flag.
set pool_error 1
}
}
when HTTP_RESPONSE priority 100 {
Catch Bad Application Errors and set relevant error flag
if { $HTTP_METHOD == "GET" } {
if { [HTTP::status] == 404 or [HTTP::status] == 500 or [HTTP::status] == 502 or [HTTP::status] == 503 } {
log local0.info "Error encountered. Returning unavailable page. Request details: HTTP_HOST=$HTTP_HOST, HTTP_URI=$HTTP_URI, HTTP_METHOD=$HTTP_METHOD, VSPool=$VSPool, HTTP_Status=[HTTP::status]"
set response_error 1
return
}
}
}
Removed it from the VIP and it's now 100% success rate...
Now to try and work out why this rule would cause the issues i was seeing...
Gav
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
