Hi David,

I confirm that there is no asterisk before JkMount.

I removed the workers.java_home and workers.tomcat_home from
workers.properties. I was just following the instructions from
http://tomcat.apache.org/connectors-doc/webserver_howto/apache.html.

mtte0303 is the hostname of the machine. And the JkMount directives are
present in the main config, not in the <VirtualHost>.

The httpd.conf file has two <VirtualHost> tags. Now I moved the JkMount
directives under two <VirtualHost> tags. Now if I access I am getting the
following error in the Internet Explorer browser:

Bad Gateway

*The proxy server received an invalid response from an upstream server*
And in the mod_jk.log the following error messages are present:

[Sat Jun 07 10:41:42 2008] [636758:3223019520] [debug] mod_jk.c (2740):
Initialized mod_jk/1.2.26
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [error] jk_ajp_common.c
(1004): (worker1) can't receive the response message from tomcat, tomcat (
127.0.0.1:2004) has forced a connection close for socket 6
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [error] jk_ajp_common.c
(1766): (worker1) Tomcat is down or refused connection. No response has been
sent to the client (yet)
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [info] jk_ajp_common.c
(2186): (worker1) sending request to tomcat failed (recoverable),
(attempt=1)
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(1352): (worker1) all endpoints are disconnected, detected by connect check
(0), cping (0), send (0)
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_connect.c (448):
socket TCP_NODELAY set to On
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_connect.c (462):
socket SO_KEEPALIVE set to On
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_connect.c (513):
timeout 60 set for socket=6
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_connect.c (548):
trying to connect socket 6 to 127.0.0.1:2004
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_connect.c (574):
socket 6 connected to 127.0.0.1:2004
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(878): Connected socket 6 to (127.0.0.1:2004)
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): sending to ajp13 pos=4 len=748 max=8192
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0000    12 34 02 E8 02 02 00 08 48 54 54 50 2F 31 2E 31  -
.4......HTTP/1.1
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0010    00 00 11 2F 74 65 73 74 61 70 70 2F 74 65 73 74  -
.../testapp/test
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0020    2E 6A 73 70 00 00 0E 31 33 35 2E 32 31 30 2E 37  -
.jsp...135.210.7
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0030    33 2E 31 32 33 00 FF FF 00 11 73 70 69 6E 65 6C  -
3.123.....mtte0303
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0050    0A A0 01 00 A4 69 6D 61 67 65 2F 67 69 66 2C 20  -
.....image/gif,.
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0060    69 6D 61 67 65 2F 78 2D 78 62 69 74 6D 61 70 2C  -
image/x-xbitmap,
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0070    20 69 6D 61 67 65 2F 6A 70 65 67 2C 20 69 6D 61  -
.image/jpeg,.ima
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0080    67 65 2F 70 6A 70 65 67 2C 20 61 70 70 6C 69 63  -
ge/pjpeg,.applic
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0090    61 74 69 6F 6E 2F 78 2D 73 68 6F 63 6B 77 61 76  -
ation/x-shockwav
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 00a0    65 2D 66 6C 61 73 68 2C 20 61 70 70 6C 69 63 61  -
e-flash,.applica
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 00b0    74 69 6F 6E 2F 76 6E 64 2E 6D 73 2D 65 78 63 65  -
tion/vnd.ms-exce
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 00c0    6C 2C 20 61 70 70 6C 69 63 61 74 69 6F 6E 2F 76  -
l,.application/v
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 00d0    6E 64 2E 6D 73 2D 70 6F 77 65 72 70 6F 69 6E 74  -
nd.ms-powerpoint
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 00e0    2C 20 61 70 70 6C 69 63 61 74 69 6F 6E 2F 6D 73  -
,.application/ms
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 00f0    77 6F 72 64 2C 20 2A 2F 2A 00 00 0F 41 63 63 65  -
word,.*/*...Acce
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0100    70 74 2D 4C 61 6E 67 75 61 67 65 00 00 05 65 6E  -
pt-Language...en
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0110    2D 75 73 00 00 0F 41 63 63 65 70 74 2D 45 6E 63  -
-us...Accept-Enc
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0120    6F 64 69 6E 67 00 00 0D 67 7A 69 70 2C 20 64 65  -
oding...gzip,.de
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0130    66 6C 61 74 65 00 00 11 49 66 2D 4D 6F 64 69 66  -
flate...If-Modif
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0140    69 65 64 2D 53 69 6E 63 65 00 00 1D 54 68 75 2C  -
ied-Since...Thu,
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0150    20 30 35 20 4A 75 6E 20 32 30 30 38 20 31 35 3A  -
.05.Jun.2008.15:
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0160    35 31 3A 31 30 20 47 4D 54 00 00 0D 49 66 2D 4E  -
51:10.GMT...If-N
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0170    6F 6E 65 2D 4D 61 74 63 68 00 00 16 22 31 63 35  -
one-Match..."1c5
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0180    2D 34 61 2D 34 34 65 65 64 35 30 36 37 33 37 38  -
-4a-44eed5067378
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0190    30 22 00 A0 0E 00 5E 4D 6F 7A 69 6C 6C 61 2F 34  -
0"....^Mozilla/4
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 01a0    2E 30 20 28 63 6F 6D 70 61 74 69 62 6C 65 3B 20  -
.0.(compatible;.
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 01b0    4D 53 49 45 20 36 2E 30 3B 20 57 69 6E 64 6F 77  -
MSIE.6.0;.Window
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 01c0    73 20 4E 54 20 35 2E 31 3B 20 53 56 31 3B 20 2E  -
s.NT.5.1;.SV1;..
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 01d0    4E 45 54 20 43 4C 52 20 31 2E 31 2E 34 33 32 32  -
NET.CLR.1.1.4322
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 01e0    3B 20 2E 4E 45 54 20 43 4C 52 20 32 2E 30 2E 35  -
;..NET.CLR.2.0.5
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 01f0    30 37 32 37 29 00 A0 0B 00 11 73 70 69 6E 65 6C  -
0727).....mtte0303
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0210    4B 65 65 70 2D 41 6C 69 76 65 00 A0 09 00 C5 43  -
Keep-Alive.....C
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0220    46 49 44 3D 35 39 31 32 33 3B 20 43 46 54 4F 4B  -
FID=59123;.CFTOK
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0230    45 4E 3D 65 33 34 63 64 35 38 64 30 65 39 64 32  -
EN=e34cd58d0e9d2
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0240    65 35 37 2D 32 45 31 38 37 41 33 38 2D 31 30 31  -
e57-2E187A38-101
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0250    38 2D 31 37 36 31 2D 33 36 45 46 30 45 44 35 39  -
8-1761-36EF0ED59
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0260    30 31 35 35 46 37 39 3B 20 76 31 73 74 3D 38 44  -
0155F79;.v1st=8D
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0270    39 39 35 30 44 37 34 44 36 38 46 46 31 46 3B 20  -
9950D74D68FF1F;.
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0280    74 73 70 61 63 65 2D 61 63 6B 2D 74 64 36 39 31  -
tspace-ack-td691
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 0290    65 3D 68 74 74 70 25 33 41 25 32 46 25 32 46 77  -
e=http%3A%2F%2Fw
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 02a0    69 6B 69 2E 77 65 62 2E 61 74 74 2E 63 6F 6D 25  -
iki.web.att.com%
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 02b0    32 46 64 69 73 70 6C 61 79 25 32 46 6A 61 76 61  -
2Fdisplay%2Fjava
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 02c0    25 32 46 43 53 50 25 32 42 53 65 72 76 6C 65 74  -
%2FCSP%2BServlet
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 02d0    25 32 42 46 69 6C 74 65 72 25 32 42 48 4F 57 25  -
%2BFilter%2BHOW%
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(934): 02e0    32 42 54 4F 00 A0 08 00 01 30 00 FF 00 00 00 00  -
2BTO.....0......
[Sat Jun 07 10:41:49 2008] [637092:3223019520] [debug] jk_ajp_common.c
(1395): (worker1) request body to send 0 - request body to resend 0
[Sat Jun 07 10:42:10 2008] [637092:3223019520] [error] jk_ajp_common.c
(1004): (worker1) can't receive the response message from tomcat, tomcat (
127.0.0.1:2004) has forced a connection close for socket 6
[Sat Jun 07 10:42:10 2008] [637092:3223019520] [error] jk_ajp_common.c
(1766): (worker1) Tomcat is down or refused connection. No response has been
sent to the client (yet)
[Sat Jun 07 10:42:10 2008] [637092:3223019520] [info] jk_ajp_common.c
(2186): (worker1) sending request to tomcat failed (recoverable),
(attempt=2)
[Sat Jun 07 10:42:10 2008] [637092:3223019520] [error] jk_ajp_common.c
(2204): (worker1) Connecting to tomcat failed. Tomcat is probably not
started or is listening on the wrong port
[Sat Jun 07 10:42:10 2008] [637092:3223019520] [debug] jk_ajp_common.c
(691): (worker1) resetting endpoint with sd = 4294967295 (socket shutdown)
[Sat Jun 07 10:42:10 2008] [637092:3223019520] [debug] jk_ajp_common.c
(2522): recycling connection pool slot=0 for worker worker1
[Sat Jun 07 10:42:10 2008] [637092:3223019520] [info] mod_jk.c (2364):
Service error=0 for worker=worker1

Please let me know am I missing any other configurations ?

Thanks
-Thanuja

On Sat, Jun 7, 2008 at 12:22 PM, David Smith <[EMAIL PROTECTED]> wrote:

> *JkMount /testapp/*.jsp worker1
>
> Maybe it's my mail client -- could you verify there is *not* an asterisk
> before JkMount in the line above I copied from your config below?
>
> Otherwise, you don't need workers.java_home or workers.tomcat_home  --
> mod_jk doesn't care where your tomcat home or jva home are.  Lastly, is
> mtte0303 a virtual host of apache or it's main identity?  I ask the last one
> because the JkMount directives have to be in the <VirtualHost> of the host
> you want to mount a webapp in.  Not the rest of the config -- just the
> JkMount and JkUnMount directives.
> --David
>
>
> Thanuja Danda wrote:
>
>> Hi Martin,
>>
>> Thanks for the reply.I do have a JkMount in $APACHE_HOME/conf/httpd.conf
>> *JkMount /testapp/*.jsp worker1*
>> Where *worker1* is a of type ajp13 and is configured in workers.properties
>> as:
>> *worker.worker1.type=ajp13*
>>
>> Please see below in the configuration. I highlighted below (in httpd.conf
>> file, I pasted)  in red color.
>>
>> Thanks
>> On Sat, Jun 7, 2008 at 10:39 AM, Martin <[EMAIL PROTECTED]> wrote:
>>
>>
>>
>>> do you have the JKMount directive in your %APACHE_HOME%/conf/httpd.conf ?
>>>
>>> # send all requests ending in .jsp to ajp13
>>> JkMount /*.jsp ajp13
>>>
>>> http://tomcat.apache.org/connectors-doc/webserver_howto/apache.html
>>>
>>> HTH
>>> Martin-
>>> ----- Original Message ----- From: "Thanuja Danda" <[EMAIL PROTECTED]>
>>> To: <users@tomcat.apache.org>
>>> Sent: Saturday, June 07, 2008 10:27 AM
>>> Subject: Configuring Apache with Tomcat using mod_jk connector
>>>
>>>
>>>
>>> Hi All,
>>>
>>>
>>>> I have an issue configuring Apache/2.2.8 (True 64 Unix) integration with
>>>> Tomcat 5.0.28 using mod_jk/1.2.26. Both Apache and Tomcat are running
>>>> on
>>>> the
>>>> same machine. While configuring, I followed the instructions from
>>>> http://tomcat.apache.org/connectors-doc/webserver_howto/apache.html. I
>>>> checked for both servers, they both are up and running. Apache is
>>>> listening
>>>> on port 80 and Tomcat is running on 2004. But when I used the URL to
>>>> access
>>>> the "testapp" context on Tomcat using the URL (of Apache):
>>>> http://mtte0303/testapp/test.jsp, the Apache is not sending the request
>>>> to
>>>> Tomcat. But when I access the tomcat URL:
>>>> http://mtte0303/testapp/test.jsp,
>>>> it's working.
>>>>
>>>> Please help me solving this issue.
>>>>
>>>> Below is the Configuration I have made:
>>>>
>>>> httpd.conf is configured as below:
>>>> ------------------------------------------------
>>>> LoadModule jk_module modules/mod_jk.so
>>>> JkWorkersFile /usr/apache/tomcat/conf/jk/workers.properties
>>>> JkShmFile /usr/apache/logs/mod_jk.shm
>>>> JkLogFile /usr/apache/logs/mod_jk.log
>>>> JkLogLevel debug
>>>> JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
>>>> JkMount /testapp/servlet/ worker1
>>>> *JkMount /testapp/*.jsp worker1
>>>> *
>>>> workers.properties is configured as below:
>>>> -----------------------------------------------------------
>>>> # Define some properties
>>>> workers.tomcat_home=/usr/apache/tomcat
>>>> workers.java_home=/usr/opt/java141
>>>> ps=/
>>>> worker.list=worker1
>>>> *# Set properties for worker1(ajp13)
>>>> worker.worker1.type=ajp13*
>>>> worker.worker1.host=localhost
>>>> worker.worker1.port=2004
>>>> worker.worker1.connection_pool_timeout=600
>>>> worker.worker1.socket_keepalive=1
>>>> worker.worker1.socket_timeout=60
>>>>
>>>> I am getting the following error messages in mod_jk.log when I access
>>>> the
>>>> above URL.
>>>>
>>>> [Sat Jun 07 08:14:19 2008] [628367:3223019520] [debug] jk_shm.c (457):
>>>> Attached shared memory [7] size=28672 free=28672 addr=0x18000
>>>> [Sat Jun 07 08:14:19 2008] [628367:3223019520] [debug] jk_shm.c (471):
>>>> Reseting the shared memory for child 7
>>>> [Sat Jun 07 08:14:19 2008] [628367:3223019520] [debug] jk_shm.c (262):
>>>> Duplicated shared memory lock /usr/apache/logs/mod_jk.shm.629169.lock
>>>> [Sat Jun 07 08:14:19 2008] [628367:3223019520] [debug] mod_jk.c (2730):
>>>> Attached shm:/usr/apache/logs/mod_jk.shm.629169 (28672 bytes)
>>>> [Sat Jun 07 08:14:19 2008] [628367:3223019520] [debug] mod_jk.c (2740):
>>>> Initialized mod_jk/1.2.26
>>>> [Sat Jun 07 08:14:49 2008] [629470:3223019520] [debug] mod_jk.c (3033):
>>>> missing uri map for mtte0303:/testapp/index.jsp
>>>> [Sat Jun 07 08:14:49 2008] [629470:3223019520] [debug] mod_jk.c (3190):
>>>> missing uri map for mtte0303:/testapp/index.jsp
>>>>
>>>> Please let me know where is the mistake ?
>>>>
>>>> Thanks in advance.
>>>>
>>>> Please note: Apache is also configure with  mod_ssl/2.2.8 OpenSSL/0.9.8g
>>>>
>>>> Regards
>>>> Thanuja
>>>>
>>>>
>>>>
>>>>
>>> ---------------------------------------------------------------------
>>> To start a new topic, e-mail: users@tomcat.apache.org
>>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>>> For additional commands, e-mail: [EMAIL PROTECTED]
>>>
>>>
>>>
>>>
>>
>>
>>
>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>

Reply via email to