Answer the question
In order to leave comments, you need to log in
Apache load balancing how to disable jumping between nodes?
Day. There is a config:
<VirtualHost 100.12.69.1:80>
ProxyRequests off
ServerName cluster.local
<Proxy balancer://cluster>
BalancerMember http://100.12.69.100:8080 route=AppNode1 loadfactor=1
BalancerMember http://100.12.69.110:8080 route=AppNode2 loadfactor=1
ProxySet lbmethod=byrequests stickysession=JSESSIONID|jsessionid
</Proxy>
ProxyPass / balancer://cluster/
ProxyPass http://100.12.69.100 http://100.12.69.100:8080
ProxyPass http://100.12.69.110 http://100.12.69.110:8080
ProxyPassReverse / http://100.12.69.100:8080
ProxyPassReverse / http://100.12.69.110:8080
</VirtualHost>
Answer the question
In order to leave comments, you need to log in
Working config:
<VirtualHost 100.12.69.1:80>
ServerName cluster.local
Header add Set-Cookie "ROUTEID=.%{BALANCER_WORKER_ROUTE}e; path=/" env=BALANCER_ROUTE_CHANGED
<Proxy balancer://cluster>
BalancerMember http://100.12.69.100:8080 route=AppNode1 loadfactor=1
BalancerMember http://100.12.69.110:8080 route=AppNode2 loadfactor=1
ProxySet lbmethod=byrequests stickysession=ROUTEID
</Proxy>
ProxyPass / balancer://cluster/
ProxyPassReverse / balancer://cluster/
</VirtualHost>
the inclusion of the balancer through the conditions of the flag through SetEnv must be controlled.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question