1. No Profile Picture
    Contributing User
    Devshed Novice (500 - 999 posts)

    Join Date
    Jul 2001
    In a constant state of turmoil
    Rep Power

    Tomcat + Apache... just about got it

    Okay, I've been at this a good part of the day and I think I'm just about there but I've got to be missing one piece of the pie.

    When I view a php page in one of my virtual host directories that I have set up, apache delivers the page just fine. When I try to view a .jsp page from the same directory I get the Tomcat "HTTP Status 404" that gives the discription "The requested resource (/myfirst.jsp) is not available". I have to assume that means I'm missing a directive for Tomcat somewhere along the way that tells it what the apache server root is.

    I've added this to my httpd.conf file

    <IfModule !mod_jk.c>
    LoadModule jk_module c:/WINDOWS/system32/mod_jk.dll

    JkWorkersFile "C:/FoxServ/Apache/conf/workers.properties"
    JkLogFile "C:/FoxServ/Apache/logs/mod_jk.log"

    JkLogLevel info

    JkMount /manager ajp13
    JkMount /manager/* ajp13

    JkMount /examples ajp13
    JkMount /examples/* ajp13

    JkMount /tomcat-docs ajp13
    JkMount /tomcat-docs/* ajp13

    JkMount /webdav ajp13
    JkMount /webdav/* ajp13

    JkMount /*.jsp ajp13

    And my httpd.conf virtual host looks like this:
    <VirtualHost *>
    DocumentRoot C:/FoxServ/www/jkyouth
    ServerName jkyouth.com
    JkMount /*.jsp ajp13
    JkMount /servlet/* ajp13
    Should I be setting up some kind of virtual host for Tomcat too?

    All help is gretly appreciated.

    Last edited by butcher; July 1st, 2003 at 09:28 PM.
  2. #2
  3. No Profile Picture
    Moderator =(8^(|)
    Devshed Intermediate (1500 - 1999 posts)

    Join Date
    Feb 2002
    Sacramento, CA
    Rep Power
    I haven't done much work with virtual servers, but yes, I'm pretty sure you need to create a new context in tomcat that points to C:/FoxServ/www/jkyouth. I just can't imagine how it could possibly work without you doing that .

IMN logo majestic logo threadwatch logo seochat tools logo