Forum Discussion
peter_siman
Nimbostratus
May 29, 2011Pool selection based on URI string
Hi,
I have writtend a simple iRule to select particular pool based on what the URI string is. See below the iRule. Unfortunatelly, when applied a following messsages show up in logs.
...
The_Bhattman
Nimbostratus
Jun 07, 2011Hi Bob,
Oops. My bad. YOu need an extra bracket
when HTTP_REQUEST {
switch -glob [HTTP::host] {
"secure2.mydomain.com" {
if { [HTTP::path] starts_with "/mcbob" } {
log local0. "Accessed when the URL is http://[HTTP::host]/[HTTP::uri]"
pool secure2.mydomain.com
}
}
"secure.mydomain.com" {
log local0. "Accessed when the URL is http://[HTTP::host]/[HTTP::uri]"
pool secure.mydomain.com
}
}
}
when SERVER_CONNECTED {
log local0. "Connection from [IP::client_addr]:[TCP::client_port] to WIN2K8 server: [IP::server_addr]:[TCP::server_port] established."
}
Bhattman
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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