Hello, I've another problem...
I've few pages that do login to reserved area via https: sometimes haproxy
maintains the same server (in http mode it redirect me to server1, during
login it make ssl connection also to server1).
Many times when I connected i http mode it give me web pages from server1
but when I do login (in https) it go to server2.
Have you got solution to lock client to the same server once connected? I've
tried "balance source" or "appsession" without success.
Here's my configuration:
listen HTTP
bind XXXXXXX:80 -> (PUBLIC IP)
mode http
balance source
stats enable
stats uri /haproxy
stats auth admin:asdasdasd
stats refresh 10s
acl indirizzo_dnshst url_end /
# acl indirizzo_dnshst1 path_beg /index
source 192.168.0.222 usesrc clientip
redirect location /dnshst/index.jsp if indirizzo_dnshst
# redirect location /dnshst/index.jsp if indirizzo_dnshst1
cookie SERVERID insert
server server1.xyz 192.168.0.150 cookie SERVER1 check port 80 inter
3000 rise 2 fall 5 maxconn 1000
server server2.xyz 192.168.0.151 cookie SERVER2 check port 80 inter
3000 rise 2 fall 5 maxconn 1000
option redispatch
option httpclose
listen HTTPS
bind XXXXXXXXXX:443
mode tcp
option forwardfor
option ssl-hello-chk
balance source
source 192.168.0.222 usesrc clientip
cookie SERVERID insert indirect
server SERVER1.XYZ 192.168.0.150 check inter 3000 rise 2 fall 5
maxconn 1000
server SERVER2.XYZ 192.168.0.151 check inter 3000 rise 2 fall 5
maxconn 1000
option redispatch
Have you got solution for my problem?
Thanks,
Carlo