Forum Discussion
sysadmin_2015_2
Aug 05, 2015Nimbostratus
iRule help - Routing traffic
Hello,
Is it possible once I implement the below iRule(25% percent of production web traffic being routed to staging_web pool) on our production web virtual server to then route all traffic from...
Aug 14, 2015
It'd be something like this:
when HTTP_REQUEST {
if { rand() > 0.25 } {
pool pool_1
} else {
pool pool_2
}
}
Please note that unless you use connection multiplexing this rule would establish a new connection server-side every fourth request (more or less). If I were you I'd change the event to CLIENT_ACCEPTED because:
- Then the connections would not have to be re-established saving server performance.
- The iRule is only executed once per connection instead of once per request saving LTM performance.
Good luck!
/Patrik
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