users@glassfish.java.net

Re: How to set jvmRoute for AJP/mod_jk load balancing

From: <glassfish_at_javadesktop.org>
Date: Thu, 01 Nov 2007 11:12:39 PST

Hi guys, I'm not able to get the patch to work for some reason. jakemann, can you run through the steps of exactly how you set this up on your machine? Any help would be greatly appreciated.

I've been through a long list of blogs trying to configure this correctly, and still keep coming up short. For some reason, mod_jk is having trouble communicating with GlassFish.

If I check the server.log for my domain, I get the following message, which seems like things are ok:
[#|2007-11-01T11:37:05.751-0500|INFO|sun-appserver9.1|javax.enterprise.system.container.web|_ThreadID=10;_ThreadName=main;|Apache mod_jk/jk2 attached to virtual-server server listening on port: 8009|#]

I installed the hello.war, and when I try to hit it with Apache\mod_jk, it seems like things start out ok:
Connected socket 840 to (127.0.0.1:8009)
sending to ajp13 pos=4 len=702 max=8192

But later, I get the following errors in the mod_jk.log:
[Thu Nov 01 12:38:38.997 2007] [5684:2232] [error] jk_ajp_common.c (1658): (worker1) Tomcat is down or refused connection. No response has been sent to the client (yet)
[Thu Nov 01 12:38:38.997 2007] [5684:2232] [info] jk_ajp_common.c (2046): (worker1) receiving from tomcat failed, recoverable operation attempt=1
[Thu Nov 01 12:38:38.997 2007] [5684:2232] [info] jk_ajp_common.c (2085): (worker1) sending request to tomcat failed, recoverable operation attempt=2
[Thu Nov 01 12:38:38.997 2007] [5684:2232] [error] jk_ajp_common.c (2097): (worker1) Connecting to tomcat failed. Tomcat is probably not started or is listening on the wrong port

I'm just not sure what is going on here.

Thanks!!
[Message sent by forum member 'javahack' (javahack)]

http://forums.java.net/jive/thread.jspa?messageID=243350