----- Original Message ----- From: "cornercuttin" <[EMAIL PROTECTED]>
To: <users@tomcat.apache.org>
Sent: Friday, August 22, 2008 2:34 PM
Subject: tomcat 6 won't generate mod_jk.conf



perhaps someone can help me here.

i am trying to get tomcat 6 to talk to apache 2.2.8 (fedora core 5), and i
can't get very far.

firstly, tomcat 6 doesn't come with a workers.properties file.

secondly, when i start tomcat via the command "./startup.sh -jkconf" or
"./startup.sh jkconf", i cannot get tomcat to create a mod_jk.conf in the
conf directory.  tomcat runs, but no file is created.

is there something that i am missing here?  i've never needed tomcat until
now, so i am new at this (tomcat), but proficient enough in apache. but all of the documentation i am finding online is saying that the mod_jk.conf file is necessary and that tomcat will create it, but i cannot seem to get it to
work.

thanks for any help.

I actually never knew it was possible from the scripts...
We always put it in the server.xml file..
but the bad news is that (I think) the autogen stuff is no longer available in 6, and if it did work would probably be wrong...

Read up on the load sharing stuff... Thats the way to go...
ie a single tomcat is just a special load sharing case...

make a mod_jk.conf file
include that in the apache httpd config... near the bottom somewhere

stick something like this in it... modify as needed
<IfModule !mod_jk.c>
 LoadModule jk_module "D:/DEV/Apache2.2/modules/mod_jk.so"
</IfModule>

JkWorkersFile conf/jk/workers.properties
JkLogFile conf/jk/mod_jk.log

JkLogLevel info

JkLogStampFormat "[%a %b %d %H:%M:%S %Y]"
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
JkRequestLogFormat "%w %V %T"

# Add shared memory.
# This directive is present with 1.2.10 and
# later versions of mod_jk, and is needed for
# for load balancing to work properly
# JkShmFile conf/jk/jk.shm

# Mount apps

   JkMount /estate/blog  lb
   JkMount /estate/eyesonly.jpg  lb
   JkMount /estate/start  lb
   JkMount /estate/*.jspx  lb
   JkMount /estate/listingEntry  lb
   JkMount /estate/*.jsp  lb
   JkMount /estate/smartText  lb


# Add the jkstatus mount point
 JkMount /jkstatus jkstatus

then make a workers.properties file
stick something like this in it

# BEGIN workers.properties
# Set properties for loadbalancer scheme
worker.list=lb,jkstatus
# Set WORKER1
worker.worker1.port=8009
worker.worker1.host=animal
worker.worker1.type=ajp13
worker.worker1.lbfactor=50
worker.worker1.recover_time=60
#worker.worker1.local_worker=1
#worker.worker1.cachesize=10
#worker.worker1.socket_keepalive=1
# Set WORKER2
worker.worker2.port=8009
worker.worker2.host=hplt1
worker.worker2.type=ajp13
worker.worker2.lbfactor=50
worker.worker2.recovery_options=60
#worker.worker2.local_worker=1
#worker.worker2.cachesize=10
#worker.worker2.socket_keepalive=1
# Set LOADBALANCER
worker.lb.type=lb
# HERE is where you decide on how many TC's there are
worker.lb.balance_workers=worker1,worker2
worker.lb.sticky_session=1
worker.lb.sticky_session=true
worker.lb.sticky_session_force=false
#worker.lb.method=B
#worker.lb.local_worker=1
# Set STATUS MONITORING
worker.jkstatus.type=status
# END workers.properties


Then make sure each tomcats ports match what you set up here... its the AJP stuff
in server.xml

Without doing much else... you will be able to access tomcat directly thru port 8080
but the apache 80 port will come thru this stuff...

The above is a test I was helping someone with... losts of commented out and in stuff...
so you can play...

Forget about the auto stuff... you dont really need it, but it was kind of nice for newbies... once ;)

Have Fun...
---------------------------------------------------------------------------
HARBOR : http://www.kewlstuff.co.za/index.htm
The most powerful application server on earth.
The only real POJO Application Server.
See it in Action : http://www.kewlstuff.co.za/cd_tut_swf/whatisejb1.htm
---------------------------------------------------------------------------



---------------------------------------------------------------------
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