Forum Discussion

GavinW_29074's avatar
GavinW_29074
Icon for Nimbostratus rankNimbostratus
Feb 07, 2012

HTTP_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 event isn't being triggered when the request is being processed.

 

This results in the site breaking as all the resource paths etc aren't being re-written by the ProxyPass irule...

 

 

An example debug log is:

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/HandleErrors : Processing HTTP_REQUEST at Priority 20...

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/HandleErrors : $maintenance_mode = 0, $ssl_error = 0, $failure_result = ''

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/CacheControl : CacheControl HTTP Request at Priority 50:

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/CacheControl : HTTP Request for Host: 192.168.151.15 URI: /home.faces

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/CacheControl : GET Method, enabling Cache

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/HandleErrors : Processing HTTP_REQUEST at Priority 750...

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/HandleErrors : $pool_error = 0

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/HandleErrors : Passed error checking... Continuing...

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : Processing ProxyPass HTTP_REQUEST

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : Not In Maintenance mode. Continuing...

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : Virtual Name = /Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, $vname = portal.comportal3.test.card.co.uk, $cname = portal, $clname = ProxyPass_portal

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : VS=/Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, Host=192.168.151.15, URI=/home.faces: HTTP connection

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : VS=/Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, Host=192.168.151.15, URI=/home.faces: Data Group ProxyPass_portal found.

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : VS=/Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, Host=192.168.151.15, URI=/home.faces: $ppass = '/ /CommercialPortal'

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : VS=/Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, Host=192.168.151.15, URI=/home.faces: ProxyPass_ value = / /CommercialPortal

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : Clientside: Path starts / Host Clientside=192.168.151.15, Path Clientside=/.

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : Serverside: Host Serverside=192.168.151.15, Path Serverside=/CommercialPortal.

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : Appending / to Path Serverside.

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : VS=/Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, Host=192.168.151.15, URI=/home.faces: Found Rule, Original Path=/home.faces, Client Host=192.168.151.15, Client Path=/, Server Host=192.168.151.15, Server Path=/CommercialPortal/

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : VS=/Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, Host=192.168.151.15, URI=/home.faces: Using default pool /Common/comportal3.test.app/comportal3.test_pool

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : VS=/Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, Host=192.168.151.15, URI=/home.faces: $bypass value = 0

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : VS=/Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, Host=192.168.151.15, URI=/home.faces: Continuing with rest of HTTP_REQUEST block.

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/CacheControl : Cache_Request for Host: 192.168.151.15 URI: /home.faces

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : VS=/Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, Host=192.168.151.15, URI=/home.faces: Processing HTTP_REQUEST_SEND block.

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : VS=/Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, Host=192.168.151.15, URI=/home.faces: New Host=192.168.151.15, New Path=/CommercialPortal/home.faces

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/ProxyPass : VS=/Common/comportal3.test.app/portal.comportal3.test.card.co.uk_http, Host=192.168.151.15, URI=/home.faces: Inserting header: X-Forwarded-For: 192.168.100.208

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/HandleErrors : Processing HTTP_REQUEST at Priority 20...

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/HandleErrors : $maintenance_mode = 0, $ssl_error = 0, $failure_result = ''

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/CacheControl : CacheControl HTTP Request at Priority 50:

 

Feb 7 17:03:53 tmm info tmm[9144]: Rule /Common/CacheControl : HTTP Request for Host: 192.168.151.15 URI: /CommercialPortal/javax.faces.resource/style.css.faces;jsessionid=8c584e5692cb13a77d7628839ebb?ln=commercial/css

 

 

AS you can see it's quite happily processing upto the HTTP_REQUEST_SEND block, but just receives no HTTP_RESPONSE.

 

However the browser appears to receive a response and moves onto requesting some of the non-rewritten resources. E.g. on the last line where it still contains 'CommercialPortal'...

 

 

Relevant config:

 

gavinw@actint-star-f501(Active)(/Common)(tmos) list /ltm virtual comportal3.test.app/portal.comportal3.test.card.co.uk_http

 

ltm virtual comportal3.test.app/portal.comportal3.test.card.co.uk_http {

 

app-service /Common/comportal3.test.app/comportal3.test

 

destination 192.168.151.15:http

 

ip-protocol tcp

 

mask 255.255.255.255

 

pool comportal3.test.app/comportal3.test_pool

 

profiles {

 

Caching_CommPortal { }

 

HTTP_Rewrite { }

 

oneconnect { }

 

stream { }

 

tcp-wan-optimized { }

 

wan-optimized-compression { }

 

}

 

rules {

 

ProxyPass

 

SplunkHTTP

 

CacheControl

 

CatchErrors

 

HeaderStripping

 

MaintenancePage

 

UnavailablePage

 

HandleErrors

 

}

 

snat automap

 

vlans-disabled

 

}

 

gavinw@actint-star-f501(Active)(/Common)(tmos) list /ltm profile web-acceleration Caching_CommPortal

 

ltm profile web-acceleration Caching_CommPortal {

 

app-service none

 

cache-uri-exclude { /home.faces }

 

cache-uri-include { .* }

 

cache-uri-include-override none

 

cache-uri-pinned { /javax.faces.resource/* }

 

defaults-from optimized-caching

 

}

 

gavinw@actint-star-f501(Active)(/Common)(tmos) list /ltm profile http HTTP_Rewrite

 

ltm profile http HTTP_Rewrite {

 

app-service none

 

defaults-from http

 

redirect-rewrite matching

 

}

 

gavinw@actint-star-f501(Active)(/Common)(tmos) list /ltm profile one-connect oneconnect

 

ltm profile one-connect oneconnect {

 

idle-timeout-override disabled

 

max-age 86400

 

max-reuse 1000

 

max-size 10000

 

source-mask any

 

}

 

gavinw@actint-star-f501(Active)(/Common)(tmos) list /ltm profile stream stream

 

ltm profile stream stream {

 

source none

 

target none

 

}

 

 

 

Any ideas what might cause this???

 

 

Cheers

 

Gavin

 

 

12 Replies

  • HTTP_* shouldn't have any special meaning for TMM. Do you have references to these variable names in your other iRules?

     

     

    Aaron
  • Aaron

     

     

    These variables were being set in this rule, and used in the 2nd rule posted above to decide if an error has been encountered which needs to be handled...

     

     

    Now that I've re-written the rules, it's been rock-solid... So must be *something* strange going on...

     

     

    Cheers

     

    Gav