Forum Discussion
Michael_Mangret
Nimbostratus
Aug 13, 2007TCL Trimright help please
Below is a call to my webservers. The Loadbalancer is resetting the connection according to my captures. I have an Irule that is listed below to trim port 80 off the call and then pass the traffic on. It does not seem to be working. I am also no seeing anything in logs that the Irule is failing. Does anyone have any insight on what may be going on with my Irule?
Here is the HTTP post.
Hypertext Transfer Protocol
POST HTTP/1.0\r\n
Server: Accipiter XML Library/8.0.Beta2 for Solaris (Ultra/Sparc)\r\n
Host: cvcars-xml.adbureau.net:80\r\n
Content-Length: 571
Content-Type: text/html\r\n
\r\n
Here is the Irule that I am using
when HTTP_REQUEST {
set http_host [HTTP::host]
if { $http_host ends_with ":80" } {
set http_host [string trimright $http_host ":80"]
log local0. "HTTP-host-trim is $http_host"
}
set host_pool [findclass $http_host $::HostPoolMap " "]
if { $host_pool ne "" } {
pool $host_pool
}
}
- hoolio
Cirrostratus
If BIG-IP is resetting the connection because of an iRule error, there should be a corresponding error logged to /var/log/ltm. It's possible that a client isn't sending the Host header at all. In that case, you would be calling 'findclass' with a null value. I'm not sure if that would generate an error or not.
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