Apache 'mod_proxy_balancer' algorithm 'bybusyness' does not balance the load after failed worker has recovered

Solution Unverified - Updated -

Issue

  • Apache 'mod_proxy_balancer' algorithm 'bybusyness' does not balance the load after failed worker has recovered. This issue does not occur with the default method (byrequests).

  • Experiencing problems with Apache's mod_proxy_balancer when a worker goes into Error state.After the underlying problem with the backend server was resolved, the worker either gets back in 'Ok' state but no requests get sent to it at all, or if requests get sent to it then the number of requests are not shared equally amongst the workers, or it stays in Error state forever. The only way to fix this problem is by doing an Apache restart.

Environment

Environment is made of an Apache mod_proxy balancer, and two Tomcat backend servers.

  • Front end server (server.example.com)

  • Red Hat Enterprise Linux 5

  • Red Hat Enterprise Linux 6
  • httpd

  • Two backend tomcat server ( backend1.example.com and backend2.example.com )

mod_proxy configuration  on  server.example.com :

<Location /balancer-manager>
SetHandler balancer-manager
</Location>

<Proxy balancer://mycluster>
BalancerMember ajp://backend1.example.com:8009  disablereuse=off ping=5 retry=60
BalancerMember ajp://backend2.example.com:8009  disablereuse=off ping=5 retry=60
</Proxy>

ProxyPass /balancer-manager !
ProxyPass /server-status !
ProxyPass / balancer://mycluster/ stickysession=JSESSIONID lbmethod=bybusyness
ProxyPassReverse / balancer://mycluster/ stickysession=JSESSIONID
ProxyPreserveHost On

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content