You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by he...@neus.com.br on 2003/04/08 15:15:24 UTC
RH+tomcat4.1.24+mod_jk2+JNI
I have tried work with tomcat+mod_jk2 "inprocess" on linux RH 8, but without success! I did the same configuration to Windows2K e all fine!
Anyone get success using RH+tomca+mod_jk2+JNI?
My configuration is the folowing:
I have touch the file /usr/local/apache2/logs/shm.file
tomcat 4.1.24
jk2.properties:
-------------------------------------------------
## THIS FILE MAY BE OVERRIDEN AT RUNTIME. MAKE SURE TOMCAT IS STOPED
## WHEN YOU EDIT THE FILE.
## COMMENTS WILL BE _LOST_
## DOCUMENTATION OF THE FORMAT IN JkMain javadoc.
# Set the desired handler list
# handler.list=apr,request,channelJni
#
# Override the default port for the socketChannel
# channelSocket.port=8019
# Default:
# channelUnix.file=${jkHome}/work/jk2.socket
# Just to check if the the config is working
shm.file=/usr/local/apache2/logs/shm.file
# Add the apr and channelJni to the list of handlers
handler.list=apr,request,container,channelJni
# The native libraries will be registered by JK2
apr.jniModeSo=inprocess
# In order to enable jni use any channelJni directive
# channelJni.disabled = 0
# And one of the following directives:
# apr.jniModeSo=/opt/apache2/modules/mod_jk2.so
# If set to inprocess the mod_jk2 will Register natives itself
# This will enable the starting of the Tomcat from mod_jk2
# apr.jniModeSo=inprocess
--------------------------------------------------------------
in apache2 (2.0.44)
workers2.properties
--------------------------------------------------------------
[shm]
file=/usr/local/apache2/logs/shm.file
size=1048576
# Define the comunication channel
[channel.jni:jni]
info=The jni channel, used if tomcat is started inprocess
# Define the parameters for the Java Virtual Machine
[vm:]
info=Parameters used to load a JVM in the server process
OPT=-Djava.class.path=/usr/local/tomcat/bin/tomcat-jni.jar
OPT=-Dtomcat.home=/usr/local/tomcat
OPT=-Dcatalina.home=/usr/local/tomcat
OPT=-Xmx256M
# JNI worker startup handler
[worker.jni:onStartup]
info=Command to be executed by the VM on startup. This one will start tomcat.
class=org/apache/jk/apr/TomcatStarter
ARG=start
stdout=${serverRoot}/logs/stdout.log
stderr=${serverRoot}/logs/stderr.log
# JNI worker shutdown handler
[worker.jni:onShutdown]
info=Command to be executed by the VM on shutdown. This one will stop tomcat.
class=org/apache/jk/apr/TomcatStarter
ARG=stop
# Map the Tomcat examples webapp to the Web server uri space
[uri:/*]
info=Map the whole webapp
-------------------------------------------------------------------
In apache2/conf/httpd.conf
LoadModule jk2_module modules/mod_jk2.so
____________________________
Neoline Webmail
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org