Forum Discussion
Glenn_32974
Nimbostratus
Jan 05, 2015Help in improve URI based irule
Hello Folks
I have the following situation...
Im deploying LTM in front of SharePoint farm that will host our new website
We are moving content from our old web servers to our new Shar...
Michael_Jenkins
Cirrostratus
Jan 05, 2015I'd recommend simplifying your iRule to something like the following if you were still wanting to use it. Otherwise, I'd suggest using a Local Traffic Policy to check the uri (and if need be, the hostname), and assign the pool that way. Using the policy, you could just have a default pool,
pool_B assigned to the Virtual Server, and then in the policy change the pool for / and /Paginas/default.aspx. Because the policy method is built-in, it's more efficient than using an iRule.
when HTTP_REQUEST {
switch -glob -- [string tolower [HTTP::path]] {
"/" -
"/paginas/default.aspx" {
log local0. "Pool A: '[HTTP::path]'"
pool pool_A
}
default {
log local0. "Pool B: '[HTTP::uri]'"
pool pool_B
}
}
}
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