Forum Discussion
Joshua_Rasnier
Nov 25, 2013Nimbostratus
Cookie persistence or Keepalives
Hi everyone,
Hope someone can shed some light.
Currently I am using a normal irule for a single virtual server as an example below.This virtual server is using custom cookie persistence.
when ...
IheartF5_45022
Nov 27, 2013Nacreous
Hi Joshy,
Could you be dropping through to the default arm (which has not been defined)? Perhaps add some logging to see what's happening. Note that with the config you have there, if the uri doesn't match the 2 arms you've defined, the request will use the pool attached to the virtual and the cookie attached to the virtual, which depending on what is there, could explain what is happening.
Hopefully the logging will explain all......
when HTTP_REQUEST {
set debug 0
if {[HTTP::header exists "X-debug"]}
set debug 1
}
Set debug logging prefix
if {$debug} {set prefix "\[[expr {int (rand() * 10000)}]\] "}
switch -glob [string tolower [HTTP::uri]] {
"/non-ssl*" {
SSL::disable serverside
persist cookie insert NONSSLCOOKIE
pool HTTP-pool
if {$debug} {log local0. "${prefix}[HTTP::uri] non-ssl"}
}
"/ssl*" {
persist cookie insert SSLCOOKIE
pool HTTPS-pool
if {$debug} {log local0. "${prefix}[HTTP::uri] non-ssl"}
}
default {
if {$debug} {log local0. "${prefix}[HTTP::uri] default"}
}
}
}
when LB_SELECTED {
if { $debug } {log local0. "${prefix}LB_SELECTED [LB::server]"}
}
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