users@glassfish.java.net

Re: Apache Glassfish and mod_jk

From: Amy Roh <Amelia.Roh_at_Sun.COM>
Date: Mon, 18 Sep 2006 11:37:09 -0700

Hi Chainy,

Which GlassFish build are you using? I just tried on Win XP with
GlassFish v1 and it works as expected.

Thanks,
Amy

Martyn wrote:
> Hi
>
> I am new to glassfish and I would like to use the mod_jk with apache and
> glassfish. Although I have followed the instructions on setting this up
> I can not get the correct results. I have read all I can find in the
> list archives but none have resolved the problem for me. When I request
> the page it seems if apache is passing on the reqest but I just get a
> blank page with no code in the source at all. On viewing the server log
> for glassfish I find this:
>
>
>
>
>
> [#|2006-09-16T03:44:13.109+0100|INFO|sun-appserver-pe9.1|org.apache.jk.server.JkMain|_ThreadID=11;_ThreadName=Thread-4;|Can't
> find home, jk2.properties not loaded|#]
>
>
>
> [#|2006-09-16T03:44:13.109+0100|INFO|sun-appserver-pe9.1|org.apache.jk.common.ChannelSocket|_ThreadID=11;_ThreadName=Thread-4;|JK:
> ajp13 listening on /0.0.0.0:8009|#]
>
>
>
> [#|2006-09-16T03:44:13.140+0100|INFO|sun-appserver-pe9.1|org.apache.jk.server.JkMain|_ThreadID=11;_ThreadName=Thread-4;|Jk
> running ID=0 time=0/47 config=null|#]
>
>
>
> And In the mod_jk log I have this
>
>
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] jk_uri_worker_map.c
> (508): Attempting to map URI '/mypage.jsp' from 2 maps
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] jk_uri_worker_map.c
> (520): Attempting to map context URI '/glassfish-test/*'
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] jk_uri_worker_map.c
> (520): Attempting to map context URI '/*.jsp'
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] jk_uri_worker_map.c
> (534): Found a wildchar match worker1 -> /*.jsp
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] mod_jk.c (1832): Into
> handler jakarta-servlet worker=worker1 r->proxyreq=0
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] jk_worker.c (111): found
> a worker worker1
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] mod_jk.c (531): Service
> protocol=HTTP/1.1 method=GET host=(null) addrr=192.168.0.3 name=stompy
> port=80 auth=(null) user=(null) laddr=192.168.0.3 raddr=192.168.0.3
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] jk_ajp_common.c (2164):
> acquired connection pool slot=0
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] jk_ajp_common.c (566):
> ajp marshaling done
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] jk_ajp_common.c (1698):
> processing worker1 with 2 retries
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] jk_connect.c (329):
> socket TCP_NODELAY set to On
>
> [Sat Sep 16 03:43:18 2006] [3260:4108] [debug] jk_connect.c (427):
> trying to connect socket 1544 to 192.168.0.3:8009
>
> [Sat Sep 16 03:43:19 2006] [3260:4108] [info] jk_connect.c (445):
> connect to 192.168.0.3:8009 failed with errno=61
>
> [Sat Sep 16 03:43:19 2006] [3260:4108] [info] jk_ajp_common.c (889):
> Failed opening socket to (192.168.0.3:8009) with (errno=61)
>
> [Sat Sep 16 03:43:19 2006] [3260:4108] [info] jk_ajp_common.c (1251):
> Error connecting to the backend server.
>
> [Sat Sep 16 03:43:19 2006] [3260:4108] [info] jk_ajp_common.c (1783):
> Sending request to tomcat failed, recoverable operation attempt=1
>
> [Sat Sep 16 03:43:19 2006] [3260:4108] [debug] jk_connect.c (329):
> socket TCP_NODELAY set to On
>
> [Sat Sep 16 03:43:19 2006] [3260:4108] [debug] jk_connect.c (427):
> trying to connect socket 1544 to 192.168.0.3:8009
>
> [Sat Sep 16 03:43:20 2006] [3260:4108] [info] jk_connect.c (445):
> connect to 192.168.0.3:8009 failed with errno=61
>
> [Sat Sep 16 03:43:20 2006] [3260:4108] [info] jk_ajp_common.c (889):
> Failed opening socket to (192.168.0.3:8009) with (errno=61)
>
> [Sat Sep 16 03:43:20 2006] [3260:4108] [info] jk_ajp_common.c (1251):
> Error connecting to the backend server.
>
> [Sat Sep 16 03:43:20 2006] [3260:4108] [info] jk_ajp_common.c (1783):
> Sending request to tomcat failed, recoverable operation attempt=2
>
> [Sat Sep 16 03:43:20 2006] [3260:4108] [error] jk_ajp_common.c (1794):
> Error connecting to tomcat. Tomcat is probably not started or is
> listening on the wrong port. worker=worker1 failed
>
> [Sat Sep 16 03:43:20 2006] [3260:4108] [debug] jk_ajp_common.c (704):
> reset socket with sd = -1
>
> [Sat Sep 16 03:43:20 2006] [3260:4108] [debug] jk_ajp_common.c (2107):
> recycling connection pool slot=0 for worker worker1
>
> [Sat Sep 16 03:43:20 2006] worker1 stompy 1.906000
>
> [Sat Sep 16 03:43:20 2006] [3260:4108] [info] mod_jk.c (1978): Service
> error=0 for worker=worker1
>
>
>
> I have entered the jvm option
> -Dcom.sun.enterprise.web.connector.enableJK=8009
>
>
>
> I have installed the latest copy of the mod_jk
>
> And apache 2.2.3 the tomcat-ajp file I copied is from version 5.5.17 as
> well as the commons jars.
>
> All on windows xp pro
>
> I would be really greatfull if someone could help me sort the issue out
>
> Kind regards Chainy.
>
>
>
>
>
>
>
>
>
>
>