Forum Discussion
Matt_Breedlove_
Nimbostratus
Jun 24, 2009single VS distributing new connections across multiple pools with persistence
We have a single VS in standard mode with 2 pools of servers. Each pool contains different servers.
VS has cookie insert persistence with named cookie and a 17min timeout.
Goal is to have ...
hoolio
Cirrostratus
Jun 25, 2009Persistence is specific to the pool. If the two pools you want to use have different members, then you would want to specify a different persistence cookie name depending on which pool to send the client to. So you could use 'persist cookie insert pool1_cookie 0' to insert a session cookie for pool 1 / use the existing cookie in the client's request to select the same pool1 member.
Here is some pseudo code to start with:
when HTTP_REQUEST {
Check if client has pool1 persistence cookie
if {[string length [HTTP::cookie value $pool1_persist_cookie_name]]}{
Client has pool1 persistence cookie. Check if pool is up?
Specify pool1 persistence to select same pool1 member
persist cookie insert $pool1_persist_cookie_name 0
Check if client has pool2 persistence cookie
} elseif {[string length [HTTP::cookie value $pool2_persist_cookie_name]]}{
Client has pool2 persistence cookie. Check if pool is up?
Specify pool2 persistence to select same pool2 member
persist cookie insert $pool2_persist_cookie_name 0
} else {
Client has no persistence cookie, so select between pool1 and pool2
Set persistence based on selected pool
}
}
Aaron
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