In addition when I start apache2 I get the following:
Starting web server: apache2[Sun Jan 09 07:52:42 2011] [warn] VirtualHost appledorera.org:80
overlaps with VirtualHost appledorera.org:80, the first has precedence, perhaps you need a
NameVirtualHost directive
Hello,
What I am trying unsuccessfully to do is - on debian (lenny) with apache2 have multiple instances
of tomcat6 each servicing a different domain using a java war/servlet
To date I have only loaded one domain "appledorera.org"
file /etc/apache2/mods-enabled/jk.load is
LoadModule jk_module /usr/lib/apache2/modules/mod_jk.so
file /etc/apache2/sites-enabled/appledorera.org is
<VirtualHost appledorera.org:80>
ServerAdmin ad...@appledorera.org
ServerName appledorera.org
ServerAlias www.appledorera.org
JkMount /* appledorera
</VirtualHost>
file /etc/apache2/workers.properties is
workers.tomcat_home = /usr/local/tomcat
workers.java_home= / usr/lib/jvm/java-6-sun
ps = /
worker.list=appledorera
Set properties for appledorera
worker.appledorera.type=ajp13
worker.appledorera.host=localhost
worker.appledorera.port=8109
file /etc/apache2/conf.d/jk.conf is
<IfModule mod_jk.c>
JkWorkersFile /etc/apache2/workers.properties
JkLogFile /var/log/apache2/mod_jk.log
JkLogLevel debug
</ifmodule>
file /usr/local/tomcat/instances/appledorera/conf/server.xml I have amended
<Server port="8005" shutdown="SHUTDOWN"> to
<Server port="8105" shutdown="SHUTDOWN">
and
<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" /> to
<Connector port="8109" protocol="AJP/1.3" redirectPort="8443" />
When the tomcat instance in /usr/local/tomcat/instances/appledorera is stopped
http://appledorera.org/ gives Service Temporarily Unavailable
and tail /var/log/apache2/mod_jk.log is
[Sun Jan 09 01:14:35.460 2011] [8183:3834091344] [debug] jk_open_socket::jk_connect.c (448):
socket TCP_NODELAY set to On
[Sun Jan 09 01:14:35.460 2011] [8183:3834091344] [debug] jk_open_socket::jk_connect.c (548):
trying to connect socket 14 to 127.0.0.1:8109
[Sun Jan 09 01:14:35.460 2011] [8183:3834091344] [info] jk_open_socket::jk_connect.c (566):
connect to 127.0.0.1:8109 failed (errno=111)
[Sun Jan 09 01:14:35.460 2011] [8183:3834091344] [info] ajp_connect_to_endpoint::jk_ajp_common.c
(869): Failed opening socket to (127.0.0.1:8109) (errno=111)
[Sun Jan 09 01:14:35.460 2011] [8183:3834091344] [error] ajp_send_request::jk_ajp_common.c (1359):
(appledorera) connecting to backend failed. Tomcat is probably not started or is listening on the
wrong port (errno=111)
[Sun Jan 09 01:14:35.460 2011] [8183:3834091344] [info] ajp_service::jk_ajp_common.c (2194):
(appledorera) sending request to tomcat failed (recoverable), because of error during request
sending (attempt=2)
[Sun Jan 09 01:14:35.460 2011] [8183:3834091344] [error] ajp_service::jk_ajp_common.c (2212):
(appledorera) Connecting to tomcat failed. Tomcat is probably not started or is listening on the
wrong port
[Sun Jan 09 01:14:35.460 2011] [8183:3834091344] [debug] ajp_reset_endpoint::jk_ajp_common.c
(691): (appledorera) resetting endpoint with sd = 4294967295 (socket shutdown)
[Sun Jan 09 01:14:35.461 2011] [8183:3834091344] [debug] ajp_done::jk_ajp_common.c (2530):
recycling connection pool slot=0 for worker appledorera
[Sun Jan 09 01:14:35.461 2011] [8183:3834091344] [info] jk_handler::mod_jk.c (2364): Service
error=-3 for worker=appledorera
When the tomcat instance in /usr/local/tomcat/instances/appledorera is started
http://appledorera.org/ gives an empty page
and tail /var/log/apache2/mod_jk.log is
[Sun Jan 09 01:11:31.376 2011] [8190:3834091344] [debug]
ajp_connection_tcp_get_message::jk_ajp_common.c (1117): 0000 04 01 90 00 0B 42 61 64 20 52 65
71 75 65 73 74 - .....Bad.Request
[Sun Jan 09 01:11:31.376 2011] [8190:3834091344] [debug]
ajp_connection_tcp_get_message::jk_ajp_common.c (1117): 0010 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 - ................
[Sun Jan 09 01:11:31.376 2011] [8190:3834091344] [debug] ajp_unmarshal_response::jk_ajp_common.c
(608): status = 400
[Sun Jan 09 01:11:31.376 2011] [8190:3834091344] [debug] ajp_unmarshal_response::jk_ajp_common.c
(615): Number of headers is = 0
[Sun Jan 09 01:11:31.376 2011] [8190:3834091344] [debug]
ajp_connection_tcp_get_message::jk_ajp_common.c (1117): received from ajp13 pos=0 len=2 max=8192
[Sun Jan 09 01:11:31.376 2011] [8190:3834091344] [debug]
ajp_connection_tcp_get_message::jk_ajp_common.c (1117): 0000 05 01 00 00 00 00 00 00 00 00 00
00 00 00 00 00 - ................
[Sun Jan 09 01:11:31.376 2011] [8190:3834091344] [debug] ajp_process_callback::jk_ajp_common.c
(1669): AJP13 protocol: Reuse is OK
[Sun Jan 09 01:11:31.376 2011] [8190:3834091344] [debug] ajp_reset_endpoint::jk_ajp_common.c
(691): (appledorera) resetting endpoint with sd = 14
[Sun Jan 09 01:11:31.376 2011] [8190:3834091344] [debug] ajp_done::jk_ajp_common.c (2530):
recycling connection pool slot=0 for worker appledorera
[Sun Jan 09 01:11:31.376 2011] [8190:3834091344] [debug] jk_handler::mod_jk.c (2348): Service
finished with status=400 for worker=appledorera
Help please
Peter
On 1/7/11 10:10 PM, Peter Sparkes wrote:
Hi,
I am having difficulties integrating tomcat6 with mod_jk. Please, does
anyone have a user friendly guide that I can use?
http://tomcat.apache.org/connectors-doc/ ?
There's an excellent example workers.properties file in the tarball of
the latest version.
p
Thanks
Peter
---------------------------------------------------------------------
To unsubscribe, e-mail:users-unsubscr...@tomcat.apache.org
For additional commands, e-mail:users-h...@tomcat.apache.org