Maybe I am missing something, but wouldn't that not be able to bind to
port 80 since Apache is already bound to it? There is a lot about the
Java world I am not familiar with, so maybe it can...



You would need separate ip addresses for apache and tomcat.



Aye I figured as much....

And indeed that is what we are doing for him right now. However, my
previous attempts at fiddling with mod_rewrite to translate root request
/whatever.jsp into /appdir/whatever.jsp had failed. I now have this
working in a preliminary stage. Since I was unable to get mod_rewrite
processing the requests right, we just did a "jkMount /* <workername>",
which passed every request off to tomcat, and since we had the "root"
context setup to serve from ~/public_html/appdir it all worked out fine.
But of course, this results in trying to pass PHP requests (and things
outside the appdir) to tomcat.




how about passing only requests that are not php to tomcat? You can do this
in httpd.conf:
<LocationMatch "^/(?!phpdir)">
jkUriSet ...
</LocationMatch>


We are using mod_jk not mod_jk2. The above would only work with mod_jk2 correct? In any case, I have finally gotten this to work (only passing off java requests to tomcat). For those interested:

in the site's root .htaccess file:
RewriteEngine On

RewriteCond %{REQUEST_URI} !^/appdir/
RewriteRule     ^(.*\.jsp)$     /appdir/$1 [L]

RewriteCond %{REQUEST_URI} !^/appdir/ [NC]
RewriteCond %{HTTP_REFERER} ^(.*)\.jsp.*$ [NC]
RewriteRule ^(.*)$      /appdir/$1 [R,NC]

then in httpd.conf, we just jkMount "/appdir/*"


Still having problems with Tomcat hanging Apache child processes. I lowered the MaxRequestsPerChild in Apache to 10. Results in more cpu work, but keeps the hung processes to a minimum. This morning there were only 3 instead of 50-200 of them. They all seem to be hanging on image files now. Weird....


-Sean

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to