Christophe_Lem2
Jun 21, 2013Cirrus
Persistence on X-Forwarded-For or Source IP
Hi,
I've got a request to make a persitence across two virtual servers but on different parameters...
The two virtual servers uses the same pool.
The client connects first on vserver1 through a proxy, where X-Forwarded-For is inserted in the HTTP header. Then the client connects to a second vserver, vserver2, without proxy. He must go to the same server as for the first request.
I've tried the following iRule but it doesn't seem to work...
when HTTP_REQUEST {
if {[HTTP::header X-Forwarded-For] != ""} then {
persist uie [HTTP::header X-Forwarded-For] 900
} else {
persist uie [IP::client_addr] 900
}
}
Any idea on how to achieve this?
Regards,
Christophe