TCL error logged when two irules are applied to HTTP and/or HTTPS vservers
Hi.
We have applied two irules to HTTP and HTTPS vservers with the same virtual IP. Both irules works fine individually. However sometimes or sporadically we are obtaining this kind of errors on /var/log/ltm:
Dec 4 13:14:51 slot1/LTMINTERNET2 err tmm[7744]: 01220001:3: TCL error: /Common/PERSISTENCE_LTCPROD - no such pool: (line 11) invoked from within "active_members -list [LB::server pool]"
First Irule is used in order to maintain persistence between HTTP and HTTP services. Pool member is inserted in a cookie, and this cookie value is used to force client requests to the same pool member for HTTP or HTTPS traffic:
when HTTP_REQUEST {
set need_cookie 1
if {[string match {*[a-zA-Z]*} [HTTP::host]]} {
set dominio [domain [HTTP::host] 2]
} else {
set dominio ""
}
if { [HTTP::cookie exists "FLTCPROD"] } {
set decrypted [HTTP::cookie decrypt "FLTCPROD" "beautifulday"]
if { ($decrypted ne "") } {
set persist_node [HTTP::cookie "FLTCPROD"]
foreach member [active_members -list [LB::server pool]] {
set node [lindex $member 0]
if { $node eq $persist_node } {
set need_cookie 0
node $persist_node [lindex $member 1]
}
}
}
}
}
when LB_FAILED {
set need_cookie 1
LB::reselect
}
when HTTP_RESPONSE {
if { $need_cookie } {
HTTP::cookie insert name "FLTCPROD" value [IP::remote_addr] path / domain $dominio
HTTP::cookie encrypt "FLTCPROD" "beautifulday"
HTTP::cookie expires "FLTCPROD" 14400
}
}
The second irule is used to manage some redirecctions depending on the URI of the request:
when HTTP_REQUEST {
if {[TCP::local_port] == 443} {
set protocolo "https"
} else {
set protocolo "http"
}
if {[string tolower [HTTP::uri]] equals "/tienda/lt/browse/productdetail.jsp?productid=a10074735&categoryid=2013.1319449414&trail=9004%3a2013.1319449414&brandid=&ancestorid=&pcproduct=true&navcount=0&isproduct=true&trailsize=1&navaction=push&groupname="} {
HTTP::respond 301 noserver Location "$protocolo://[HTTP::host]/2-con-gel-dualuxe/product/A10074735/"
} elseif {[string tolower [HTTP::uri]] equals "/tienda/lt/index.jsp"} {
HTTP::respond 301 noserver Location "$protocolo://[HTTP::host]/"
} elseif {[string tolower [HTTP::uri]] equals "/tienda/lt/browse/category.jsp?navaction=push&navcount=0&categoryid=2013.1319445491&menu=top"} {
HTTP::respond 301 noserver Location "$protocolo://[HTTP::host]/electronica/2013.5094016/category/"
} elseif {[string tolower [HTTP::uri]] equals "/tienda/lt/browse/category.jsp?navaction=push&navcount=0&categoryid=2013.1319446230&menu=top"} {
HTTP::respond 301 noserver Location "$protocolo://[HTTP::host]/television-y-video/2013.5097016/category/"
} elseif {[string tolower [HTTP::uri]] equals "/tienda/lt/browse/category.jsp?navaction=push&navcount=0&categoryid=2013.1319446255&menu=top"} {
HTTP::respond 301 noserver Location "$protocolo://[HTTP::host]/informatica/2013.5098016/category/"
} elseif {[string tolower [HTTP::uri]] equals "/tienda/lt/browse/category.jsp?navaction=push&navcount=0&categoryid=2013.1319452459&menu=top"} {
HTTP::respond 301 noserver Location "$protocolo://[HTTP::host]/salud/2013.5231016/category/"
} elseif {[string tolower [HTTP::uri]] equals "/tienda/lt/browse/category.jsp?navaction=push&navcount=0&categoryid=2013.1319446302&menu=top"} {
HTTP::respond 301 noserver Location "$protocolo://[HTTP::host]/hogar/2013.5099016/category/"
} elseif {[string tolower [HTTP::uri]] equals "/tienda/lt/browse/category.jsp?navaction=push&navcount=0&categoryid=2013.1319446354&menu=top"} {
HTTP::respond 301 noserver Location $protocolo://[HTTP::host]/cocina/2013.5100016/category/"
} elseif {[string tolower [HTTP::uri]] equals "/tienda/lt/browse/category.jsp?navaction=push&navcount=0&categoryid=2013.1319446375&menu=top"} {
HTTP::respond 301 noserver Location "$protocolo://[HTTP::host]/deportes/2013.5101016/category/"
} elseif {[string tolower [HTTP::uri]] equals "/tienda/lt/browse/category.jsp?navaction=push&navcount=0&categoryid=2013.1319528446&menu=top"} {
HTTP::respond 301 noserver Location "$protocolo://[HTTP::host]/tv/2013.5238016/category/"
}
}
We notice this error is logged when you try one of the redirections using web browser, and you already have surfed across our site (we already have a cookie assigned inserted by BIG-IP, using our first iRule). If you try to get one of our redirections for the first time (with browser cache and cookies cleared) error is not logged. Anyway all seems to work fine besides tcl message error has been logged.
anybody could help us to troubleshoot or find explanation about why this error message is being logged?
Thanks.