Forum Discussion
Deon
Nimbostratus
Sep 26, 2008Select Alternate Pool Based On Client IP?
This would appear to be a common enough idea but I can't locate any examples that lead me down the direction I need. I am looking for an iRule that looks at the client IP address at the time the load...
Deon
Nimbostratus
Sep 26, 2008OK, I think I might have the solution figured out. This is what I have so far and it appears to be working. Anybody see any issue with what I am doing here? Critiques welcome!
-Deon
when RULE_INIT {
log local0. "Select_CSS_Pool rule loading..."
}
when CLIENT_ACCEPTED {
log local0. "Select_CSS_Pool: accepted client"
TCP::collect
}
when CLIENT_DATA {
set clientip [IP::client_addr]
log local0. "Select_CSS_Pool: accepted client- $clientip"
if { $clientip starts_with "172.22.166." } {
log local0. "Selecting alternate pool CSS_2"
pool CSS_2
}
TCP::release
}
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