Forum Discussion
Help? Production PERSIST iRule not playing nice in production
I have the following iRule behind a universal persist profile. It's been tested in a non-prod environment without any reported issues, but I have problem with it in production. It also is double assigned...2 VIPs use it and both work in non-prod but only 1 works correct in production.
I've checked all the VIP settings to match other others and I still am stumped.
Can somone offer suggestions as to what might be wrong? What I see with the logging is that it appears it's either not creating a persist record or not using the one that was created.
non-prod unit: 3600 with LTM 10.2.1
prod unit: 6900 with LTM 10.2.1
when HTTP_REQUEST {
Look for existing pool cookie otherwise determine where to go based on
a lookup of client IP in the WFA Price Server addresses datalist
Created 6/30/2011 by JHook
set to 1 to enable LTM logging, 0 to disable LTM logging
set debugRAPS 1
init flag whether to run iRule or just exit
set ShouldExitRAPS 0
set PersistKeyRAPS [HTTP::header value "ConnectionId"]
if {[string tolower [HTTP::path]] starts_with "/streamer" || [string tolower [HTTP::path]] contains "sso.aspx?env" } {
} else {
stop running the iRule since PERSIST profile will pick up /streamer calls
set ShouldExitRAPS 1
return
}
switch [HTTP::cookie "TFPoolId"] {
"1" { set PoolIdRAPS "BLTCP_WEB_STREAMER" }
"2" { set PoolIdRAPS "WSI_WEB_STREAMER" }
default { set PoolIdRAPS "BLTCP_WEB_STREAMER" }
}
pool $PoolIdRAPS
if {$debugRAPS}{log local0.info "Cookie Pooling [IP::client_addr] to $PoolIdRAPS"}
if { $PersistKeyRAPS ne ""} {
if {$debugRAPS}{log local0.info "2- Found sticky header key > $PersistKeyRAPS"}
persist uie $PersistKeyRAPS 3600
if {[persist lookup uie $PersistKeyRAPS] ne "" } {
if {$debugRAPS}{log local0.info "3- Persist lookup Key: $PersistKeyRAPS > Value: [persist lookup uie $PersistKeyRAPS]"}
} else {
if {$debugRAPS}{log local0.info "3- Persist lookup > No Record Found"}
}
} else {
if {$debugRAPS}{log local0.info "2- No sticky header key"}
}
}
when HTTP_RESPONSE {
Insert header with responding server IP
HTTP::header replace "serverIP" [IP::server_addr]
}
when LB_SELECTED {
if {$ShouldExitRAPS} { return }
if {$debugRAPS}{log local0.info "4- Key: $PersistKeyRAPS > LB to: [LB::server addr]"}
}
1 Reply
- santosh_81454
Nimbostratus
Hi Jason,
Not sure if this helps.. but can you try to create a Source Address Afinity Persistence profile and enable the option to "Match across virtual servers".
Then remove the irule on both the VS and use the above created persistence profile to both the VS. ?
santosh.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* 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
