Forum Discussion
Gary_Bright_120
Nimbostratus
Mar 13, 2006Persist iRule based on URI
Hi there I'm trying to write an iRule that will allow us Admins the choice of selecting a pool member and have persistence with that member.
At the moment we have a persistance profile or source_a...
Deb_Allen_18
Mar 15, 2006Historic F5 Account
Since you are trying to insert a persistence record, rather than use an existing one, I think you need to use "persist add", and place the command AFTER the load balancing decision, so it can add the results of the load balancing decision to the persistence table:
if { [URI::decode [string tolower [HTTP::uri]]] contains "gb=3" } {
pool webpool member 1.1.1.3 80
persist add source_addr 1800
log "Persist Setup to Member 3"
}
(also, FYI: "use pool X" is legacy v4 syntax which at some point will be deprecated. For forward compatibility, use instead "pool X")
HTH
/d
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