Forum Discussion
Rick_110395
Jan 11, 2012Nimbostratus
Pool Persistence while buiilding the page
I have an iRule that selects a pool based on the URI, but as the page is built subsequent requests do not match the initial condition directing it to the same pool. How do I get the conversation to stick to the original pool it was sprayed to?
Running 10.2.2 HF3
The initial request goes to test-pool-5002 because the URI contains "Test", but as the login page is built the browser makes several additional HTTP requests that do not contain "Test" which then get sent to prod-pool-5001.
when HTTP_REQUEST {
set uri [HTTP::uri]
if { $uri contains "Test" } {
pool test-pool-5002
} else {
pool prod-pool-5001
}
}
Pools
pool test-pool-5002 {
lb method member observed
action on svcdown reselect
monitor all tcp
members 10.20.20.70:5002 {}
}
pool test-pool-5001 {
lb method member observed
action on svcdown reselect
monitor all tcp
members 10.20.20.70:5001 {}
}
I have tried using cookie persistence with no luck. Is there a way to do this without splitting it out into two virtual servers? I am open to any solution.
- Colin_Walker_12Historic F5 AccountThere are a couple of ways around this. Persistence of some form (cookie, IP, etc.) should do the trick as once the pool is chosen the client should stick there throughout their connection. That should be the simplest way to go about things. I'm surprised you tried cookie persistence with no luck. What did your config look like? What was the behavior? Were there any errors showing in the logs?
- hooleylistCirrostratusThere's a related example for persisting across pools in this thread:
- Rick_110395NimbostratusTry tried changing my iRule and just adding the prod-pool-5001 as the default pool, but got the same results
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