Forum Discussion
AlfaSpider_3544
May 04, 2012Nimbostratus
irule for virtual server to redirect to different pool
Well.....This doesn't work. Any help would be much appreatiated.
when HTTP_REQUEST {
if { [HTTP::uri] contains "mywebsite.com/util" } {
pool my-util-pool
} }
...
hoolio
May 04, 2012Cirrostratus
Hi,
If I help do I get a discount on my utilities? 🙂
Can you try this example which checks the combined host header and path values set to lower case to select the pool? The non-matching requests will use the virtual server's default pool.
when CLIENT_ACCEPTED {
Save the name of the VS default pool
set default_pool [LB::server pool]
}
when HTTP_REQUEST {
switch -glob [string tolower [HTTP::host][HTTP::path]] {
"*mywebsite.com/util*" {
"*seattle.gov/util*" } {
pool spu-util-pool
}
default {
pool $default_pool
}
}
}
Aaron
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