Apache : Load Balancing e sticky session
di
pubblicato il 05-09-2017 alle 11:52 (3923 Visite)
Interessante pagina per l'argomento nel titolo: https://httpd.apache.org/docs/2.4/mo..._balancer.html
da rimarcare l'esempio seguente :
Another example of how to provide load balancing with stickyness using mod_headers, even if the back-end server does not set a suitable session cookie:
Header add Set-Cookie "ROUTEID=.%{BALANCER_WORKER_ROUTE}e; path=/" env=BALANCER_ROUTE_CHANGED <Proxy "balancer://mycluster"> BalancerMember "http://192.168.1.50:80" route=1 BalancerMember "http://192.168.1.51:80" route=2 ProxySet stickysession=ROUTEID </Proxy> ProxyPass "/test" "balancer://mycluster" ProxyPassReverse "/test" "balancer://mycluster"