Currently,
I have the following iRules in place,
when LB_SELECTED {
set nodeip [getfield [LB::server] " " 2]
log "[IP::remote_addr] -> Noeud $nodeip"
session add uie [IP::remote_addr] $nodeip 1800
log "Dans la table [session lookup uie $nodeip]"
log "Noeud traitant la connexion : $nodeip"
}
This one is attached to a VIP for RTSP traffic. Connections always arrive first on this VIP, so the session table should be populated.
when HTTP_REQUEST {
set realip [HTTP::header "x-nokia-ip-address"]
set lll [list $realip any]
set realnode [persist lookup universal $realip]
log "lll -> $lll"
set realnode [session lookup uie $lll]
log "Lookup de $realip : [session lookup uie $lll] "
log " Noeud switch $realnode"
node $realnode
pool ECDS-NIN-STREAMEZZO-RTSP member $realnode
log "Choix du noeud $realnode pour client $realip"
}
This is rule is attached to a HTTP VIP where no persistence profile is attached as it’s not need. We only want to lookup the session table and find the matching IP extract from the HTTP header “x-nokia-ip-address”, and direct this http connection to the node handling the RTSP connection.
It is clearer ?