Forum Discussion
jburford2
Nimbostratus
Mar 30, 2022URL and URI redirect
My F5 has one virtual server for all URL's. I need to set a pool based on one of two matching URL's and a matching URI. the code below is what I am trying, the F5 gives me error everytime I try to up...
jburford2
Nimbostratus
Apr 01, 202201070151:3: Rule [/Common/KTN_ROUTER] error: /Common/KTN_ROUTER:30: error: [missing a script after "if"][ ]
/Common/KTN_ROUTER:32: error: [undefined procedure: pool "X_NEW"][{pool "X_NEW"}]
/Common/KTN_ROUTER:34: error: [undefined procedure: Else][Else]
/Common/KTN_ROUTER:38: error: [missing a script after "if"][ ]
/Common/KTN_ROUTER:40: error: [undefined procedure: pool "Y_NEW"][{ pool "Y_NEW"}]
when HTTP_REQUEST {
set host [string tolower [HTTP::host]]
set uri [string tolower [HTTP::uri]]
if { $host contains ".x." } {
if { $uri starts_with "/new" }
{pool "X_NEW"}
}
Else
if { $host contains ".y." } {
if { $uri starts_with "/new" }
{ pool "Y_NEW"}
}
}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
