-   Linux - Software (
-   -   Some apache and Tomcat Help pls... (

Evilone 03-10-2004 08:04 AM

Some apache and Tomcat Help pls...

I've set up a slack 9.1 box here at the uni where i work, i've configured apache 2, tomcat 4, and mod_jk. It's working ok, and i've added entries into httpd.conf that allow me to use the tomcat examples without using the :8080 on my url. This says to me that mod_jk is working fine. I've a few questions thought.

Here's what i added to httpd.conf, so ya'll can see what i'm whittering on about:

LoadModule jk_module modules/

#Start The Tomcat config

JkWorkersFile /usr/local/jakarta-tomcat-4.1.30/conf/jk/
JkLogFile /usr/local/jakarta-tomcat-4.1.30/logs/mod_jk.log
#JkLogLevel debug
JkLogLevel info
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
JkRequestLogFormat "%w %V %T"

#Start the tomcat mappings

Alias /examples /usr/local/jakarta-tomcat-4.1.30/webapps/examples
JkMount /*.jsp worker1
JkMount /examples/jsp/* worker1
JkMount /examples/servlet/* worker1
JkMount /webdav/* worker1
JkMount /tomcat-docs/* worker1
JkMount /admin/* worker1
JkMount /manager/* worker1
JkMount /ade/*.jsp worker1
JkMount /hn305891/*.jsp worker1
JkMount /cp921406/*.jsp worker1
Alias /ade /usr/local/jakarta-tomcat-4.1.30/webapps/ROOT/ade
Alias /hn305891 /usr/local/jakarta-tomcat-4.1.30/webapps/ROOT/hn305891
Alias /cp921406 /usr/local/jakarta-tomcat-4.1.30/webapps/ROOT/cp921406
<Location "/examples/web-inf/">
AllowOverride None

My question is this :

i've added 3 folders under the webapps/ROOT/ folder of tomcat, ade, hm305891, and cp921406. You can see where i've added alias's , they work great, it's the JkMount statements i'm after more info on. Take this one for example :

JkMount /ade/*.jsp worker1

Does this mean that any jsp file that is under ade or any subdir under ade will be passed through to tomcat. Could someone explain a little how JkMount works. I've stubled through it so far, with successfull results, but i'm confused. Is there a way that i could just say, any jsp file under ROOT no matter what subdir would be forwarded to tomcat?

I thought JkMount /*.jsp worker1 would do it, but it seems only to work in the ROOT folder and not in subdirs.

The reason i ask is in the coming months i'll be adding possibly hundreds of accounts for our students, and i don't want to have to add in a JkMount for every student dir i create. There has to be an easier way.

Cheers in advance,


Evilone 03-11-2004 04:23 AM

I Can't beliieve it dropped to page 4.... Come on peeps...


Amplifity 03-30-2004 07:59 PM

Did you figure this out. Just wondering, I think I've seen before where you could put /* and it would effect everything under it.

I would also like to know what documentation or where you got documentation that helped you set up Apache and Tomcat. I can't get it to work. I'm running Fedora Core 1, with the latest Apache, and Tomcat 5. I think I'm close, I just don't know what I'm missing. I've even tried the developer edition of JRun 4 from Macromedia. I'm seeing some wierd things go on with files.

All times are GMT -5. The time now is 11:30 PM.