Title: mod_jk load balancing

Hi everyone,

I am trying to configure the Apache server to balance the load between two independent Tomcat workers using ajp12 protocol.

One worker is listening on port 10101, another one on port 10102. I put in my workers.properties file:

worker.ajp12.port=10101
worker.ajp12.host=localhost
worker.ajp12.type=ajp12
worker.ajp12.lbfactor=1

worker.ajp13.port=10103
worker.ajp13.host=localhost
worker.ajp13.type=ajp12
worker.ajp13.lbfactor=1

worker.loadbalancer.type=lb
worker.loadbalancer.balanced_workers=ajp12, ajp13

At first I put in my apache configuration file :

JkMount /apps-jsp/servlet/* loadbalancer
JkMount /apps-jsp/*.jsp loadbalancer

thinking, that this way mod_jk will process requests via loadbalancer worker, but I got "Internal Server Error"
After that, I changed it back to:

JkMount /apps-jsp/servlet/* ajp12
JkMount /apps-jsp/*.jsp ajp12

Servlets started working, but log files are showing no load balancing, all requests are processes via port 10101.

Does anyone know, what should I put into Apache configuration file to achieve load balancing?

Thank you very much in advance,
Margaret Royzen.


Reply via email to