Forum Discussion
hooleylist
Mar 28, 2012Cirrostratus
Hi Stolivar,
Can you try this version of the iRule which explicitly selects a pool for all cases? Once you're done testing, you can disable or remove the debug logging.
when CLIENT_ACCEPTED {
Log debug to /var/log/ltm? 1=yes, 0=no.
set switch_debug 1
Save the name of the VS default pool before the iRule could change it
set default_pool [LB::server pool]
}
when HTTP_REQUEST {
switch [string tolower [HTTP::host]] {
www.host2.com {
pool host2
if {$switch_debug}{log local0. "[IP::client_addr]:[TCP::client_port]: Using host2 pool for [HTTP::host][HTTP::uri]"
return
}
www.host1.com {
switch -glob [string tolower [HTTP::uri]] {
"/itunesu*" -
"/pubservices-war*" -
"/ref_form*" -
"/ccv*" {
pool www.host1-Tomcat
if {$switch_debug}{log local0. "[IP::client_addr]:[TCP::client_port]: Using www.host1-Tomcat pool for [HTTP::host][HTTP::uri]"}
return
}
}
}
}
If we are still in the iRule select the VS default pool
pool $default_pool
if {$switch_debug}{log local0. "[IP::client_addr]:[TCP::client_port]: Using $default_pool pool for [HTTP::host][HTTP::uri]"}
}
when LB_SELECTED {
if {$switch_debug}{log local0. "[IP::client_addr]:[TCP::client_port]: Selected [LB::server]"}
}
when SERVER_CONNECTED {
if {$switch_debug}{log local0. "[IP::client_addr]:[TCP::client_port]: Connected [IP::server_addr]:[TCP::client_port]"}
}
Aaron