Glassfish 3.1.2. Balancing Apache2 with mod_jk

We use Glassfish 3.1.2, which is loaded by Apache using mod_jk, however, when I turn on ping_mode in C or A, it does not work, it just says

[Wed May 09 08:17:05 2012] [15033:140400029296384] [info] ajp_handle_cping_cpong::jk_ajp_common.c (889): awaited reply cpong, not received
[Wed May 09 08:17:05 2012] [15033:140400029296384] [error] ajp_connect_to_endpoint::jk_ajp_common.c (992): (worker2) cping/cpong after connecting to the backend server failed (errno=0)
[Wed May 09 08:17:05 2012] [15033:140400029296384] [error] ajp_send_request::jk_ajp_common.c (1585): (worker2) connecting to backend failed. Tomcat is probably not started or is listening on the wrong port (errno=0)
[Wed May 09 08:17:05 2012] [15033:140400029296384] [info] ajp_service::jk_ajp_common.c (2540): (worker2) sending request to tomcat failed (recoverable), because of error during request sending (attempt=19)
[Wed May 09 08:17:06 2012] [15033:140400029296384] [info] ajp_connection_tcp_get_message::jk_ajp_common.c (1223): (worker2) can't receive the response header message from tomcat, tomcat (192.168.42.83:8009) has forced a connection close for socket 15

However, if I comment on the next line, it works fine, any ideas?

worker.template.ping_mode=A

My whole working file is as follows.

worker.list=loadbalancer, status

worker.template.type=ajp13
worker.template.port=8009
worker.template.lbfactor=1
worker.template.socket_timeout=10
worker.template.ping_timeout=10000
worker.template.ping_mode=A
worker.template.connection_pool_size=25
worker.template.connection_pool_timeout=300
worker.template.retries=20

worker.worker1.reference=worker.template
worker.worker1.host=node1

worker.worker2.reference=worker.template
worker.worker2.host=node2

worker.loadbalancer.type=lb
worker.loadbalancer.balance_workers=worker1,worker2

worker.status.type=status
+3
source share

All Articles