Forum Discussion
Tomasz_93254
Feb 18, 2011Nimbostratus
Irule strange problem
I have the following Irule on my LTM F5:
when HTTP_REQUEST {
set subpath [HTTP::uri]
if {[HTTP::host] equals "aaa.co.uk"} { HTTP::respond 301 Location "http://www.aaa.co.uk...
hooleylist
Feb 18, 2011Cirrostratus
Can you try this? It's explicitly setting the pool or redirect for each case.
when CLIENT_ACCEPTED {
Save the VS default pool name
set default_pool [LB::server pool]
}
when HTTP_REQUEST {
switch [string tolower [HTTP::host]] {
"aaa.co.uk" { HTTP::respond 301 Location "http://www.aaa.co.uk[HTTP::path]" }
"www.aaa.co.uk" { pool pl_it_www-aaa-co-uk_p80 }
"www.aaa.com" { pool pl_it_www-aaa-com_p80 }
"bbb.com" { HTTP::respond 301 Location "http://www.bbb.com[HTTP::path]" }
"www.bbb.com" {
switch -glob [HTTP::path] {
"*/qqq*" { HTTP::respond 301 Location "http://www.bbb.com" }
"*/default.html" { HTTP::respond 301 Location "http://www.bbb.com" }
default { pool pl_it_www-bbb-com_p80 }
}
}
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