You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by AbelMacAdam <ab...@gmail.com> on 2007/12/18 09:13:12 UTC

Configuring mod_jk?

Hi,

Yesterday I tried to integrate Tomcat (6.0.14) in my Apache (2.2.6). I saw a
document about how to do it, but had not have the time to test it (really).
But the appache_error.log states:
[Tue Dec 18 08:54:35 2007] [warn] No JkLogFile defined in httpd.conf. Using
default C:/wamp/bin/apache/apache2.2.6/logs/mod_jk.log

My httpd.conf contains the following entries:
LoadModule       jk_module modules/mod_jk.so
AddModule        mod_jk.c
JkWorkersFile    C:/Program Files/Apache Software Foundation/Tomcat
6.0/conf/workers.properties 
JkLogFile        C:/wamp/logs/mod_jk.log
JkLogLevel       info
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] " 
It is very basic. But it contains an entry for JkLogFile, which is not used
by Apache. How come?

Abel
-- 
View this message in context: http://www.nabble.com/Configuring-mod_jk--tp14384532p14384532.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Configuring mod_jk?

Posted by Rainer Jung <ra...@kippdata.de>.
AbelMacAdam schrieb:
> You where right, the line containing JkWorkersFile generated an error:
> Syntax error on line 499 of C:/wamp/bin/apache/apache2.2.6/conf/httpd.conf:
> JkWorkersFile takes one argument, the name of a worker file for the Tomcat 
> servlet containers
> I changed the JkWorkersFile to:
> JkWorkersFile    C:/wamp/conf/tomcat/workers.properties 
> 
> It works. Thanks for your help.
> 
> Abel

Good to know. Most likely you can put a path with white space into
quotation marks, but you might stumple repeatedly into those kinds of
problems, so it's usually safer to not use white space in pathes.

Have fun.

Rainer

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Configuring mod_jk?

Posted by AbelMacAdam <ab...@gmail.com>.

Rainer Jung-3 wrote:
> 
>>> Which version of mod_jk are you using?
>> ==> 2.2.6
> 
> No that's the httpd version. JK version should be 1.2.something.
> 
You are right, it is 1.2.25.


The default file normally doesn't get used. It's kind of template from
> which you can regenerate an original config. Whoever put the AddModule
> in there mixed up Apache 1.3 with 2.2, not a good sign :(

I talked to the person who put that configuration in the
~/default/httpd.conf file,
* see me muttering in myself *
The offending lines are now removed.


Minimum (assuming your jk module really sits in the correct moudules
> directory):
> 
> LoadModule       jk_module modules/mod_jk.so
> JkLogFile        C:/wamp/logs/mod_jk.log
> JkLogLevel       info
> 
> plus (but better use a directory without spaces in the path, it doesn't
> have to be in the Tomcat directory):
> 
> JkWorkersFile    C:/Program Files/Apache Software Foundation/Tomcat
> 6.0/conf/workers.properties
> 
You where right, the line containing JkWorkersFile generated an error:
Syntax error on line 499 of C:/wamp/bin/apache/apache2.2.6/conf/httpd.conf:
JkWorkersFile takes one argument, the name of a worker file for the Tomcat 
servlet containers
I changed the JkWorkersFile to:
JkWorkersFile    C:/wamp/conf/tomcat/workers.properties 

It works. Thanks for your help.

Abel
-- 
View this message in context: http://www.nabble.com/Configuring-mod_jk--tp14384532p14398010.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Configuring mod_jk?

Posted by Rainer Jung <ra...@kippdata.de>.
AbelMacAdam schrieb:
>>> My httpd.conf contains the following entries:
>>> LoadModule       jk_module modules/mod_jk.so
>>> AddModule        mod_jk.c
>>> JkWorkersFile    C:/Program Files/Apache Software Foundation/Tomcat
>>> 6.0/conf/workers.properties 
>>> JkLogFile        C:/wamp/logs/mod_jk.log
>>> JkLogLevel       info
>>> JkLogStampFormat "[%a %b %d %H:%M:%S %Y] " 
>>> It is very basic. But it contains an entry for JkLogFile, which is not
>>> used
>>> by Apache. How come?
>> Which version of mod_jk are you using?
> ==> 2.2.6

No that's the httpd version. JK version should be 1.2.something.

> Are there any VirtualHosts in your httpd configuration?
> ==> No
> 
> 
> I expect, your httpd uses another config file. 
> ==> Would that be 
> C:\wamp\bin\apache\apache2.2.6\conf\default\httpd.conf
> or 
> C:\wamp\bin\apache\apache2.2.6\conf\httpd.conf?
> (if not obvious, I work with XP and have a wamp server installed.)

The default file normally doesn't get used. It's kind of template from
which you can regenerate an original config. Whoever put the AddModule
in there mixed up Apache 1.3 with 2.2, not a good sign :(

You can simply test which file gets used yourself by temporarily
renaming the files.

> In the snippet you show us, there is an AddModule directive, which only
> existed 
>> for Apache httpd 1.3, but not for 2.2. 
> ==> You might be right. The first config file (the one in ~\conf\default)
> has the 
> AddModule directive. The second one not. The second one uses:
> LoadModule jk_module modules/mod_jk.so
> 
> If I remove the lines I added in the first config file (~\conf\default),
> what should I 
> add to the second one to get it to log the errors correct?

Minimum (assuming your jk module really sits in the corrcet moudles
directoty):

LoadModule       jk_module modules/mod_jk.so
JkLogFile        C:/wamp/logs/mod_jk.log
JkLogLevel       info

plus (but better use a directory without spaces in the path, it doesn't
have to be in the Tomcat directory):

JkWorkersFile    C:/Program Files/Apache Software Foundation/Tomcat
6.0/conf/workers.properties

More details on

http://tomcat.apache.org/connectors-doc/reference/apache.html

Regards,

Rainer

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Configuring mod_jk?

Posted by AbelMacAdam <ab...@gmail.com>.
Hi Rainer,



Rainer Jung-3 wrote:
> 
>> My httpd.conf contains the following entries:
>> LoadModule       jk_module modules/mod_jk.so
>> AddModule        mod_jk.c
>> JkWorkersFile    C:/Program Files/Apache Software Foundation/Tomcat
>> 6.0/conf/workers.properties 
>> JkLogFile        C:/wamp/logs/mod_jk.log
>> JkLogLevel       info
>> JkLogStampFormat "[%a %b %d %H:%M:%S %Y] " 
>> It is very basic. But it contains an entry for JkLogFile, which is not
>> used
>> by Apache. How come?
> 
> Which version of mod_jk are you using?
==> 2.2.6

Are there any VirtualHosts in your httpd configuration?
==> No


I expect, your httpd uses another config file. 
==> Would that be 
C:\wamp\bin\apache\apache2.2.6\conf\default\httpd.conf
or 
C:\wamp\bin\apache\apache2.2.6\conf\httpd.conf?
(if not obvious, I work with XP and have a wamp server installed.)


In the snippet you show us, there is an AddModule directive, which only
existed 
> for Apache httpd 1.3, but not for 2.2. 
==> You might be right. The first config file (the one in ~\conf\default)
has the 
AddModule directive. The second one not. The second one uses:
LoadModule jk_module modules/mod_jk.so

If I remove the lines I added in the first config file (~\conf\default),
what should I 
add to the second one to get it to log the errors correct?


Thanks,
Abel
-- 
View this message in context: http://www.nabble.com/Configuring-mod_jk--tp14384532p14396214.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Configuring mod_jk?

Posted by Rainer Jung <ra...@kippdata.de>.
Hi Abel,

AbelMacAdam schrieb:
> Hi,
> 
> Yesterday I tried to integrate Tomcat (6.0.14) in my Apache (2.2.6). I saw a
> document about how to do it, but had not have the time to test it (really).
> But the appache_error.log states:
> [Tue Dec 18 08:54:35 2007] [warn] No JkLogFile defined in httpd.conf. Using
> default C:/wamp/bin/apache/apache2.2.6/logs/mod_jk.log
> 
> My httpd.conf contains the following entries:
> LoadModule       jk_module modules/mod_jk.so
> AddModule        mod_jk.c
> JkWorkersFile    C:/Program Files/Apache Software Foundation/Tomcat
> 6.0/conf/workers.properties 
> JkLogFile        C:/wamp/logs/mod_jk.log
> JkLogLevel       info
> JkLogStampFormat "[%a %b %d %H:%M:%S %Y] " 
> It is very basic. But it contains an entry for JkLogFile, which is not used
> by Apache. How come?

Which version of mod_jk are you using?
Are there any VirtualHosts in your httpd configuration?

I expect, your httpd uses another config file. In the snippet you show
us, there is an AddModule directive, which only existed for Apache httpd
1.3, but not for 2.2. So your httpd should not startup with this
configuration.

Regards,

Rainer

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org