5 Replies Latest reply on Dec 14, 2010 2:58 AM by Jean-Frederic Clere

    Problem in configuring mod_jk1.2 with JBoss and a separate Tomcat

    Pankaj Verma Newbie

      Hi

       

      Our web application uses JBoss 5.1.0 GA as an Application Server and a separate Tomcat (6.0) instance as a web server to connect to JBoss. The web server uses 1099 port of JBoss to connect to it and avail its services. We are trying to use mod_jk with the tomcat instance (Web Server) and are trying to follow the instructions mentioned in the following link:

       

      http://threebit.net/mail-archive/tomcat-users/msg00019.html

       

      Following issues we are facing in doing the configuration mentioned in the above link:

       

      1. The configuration instruction says to enter following statements in the httpd.conf file but our tomcat instance does not have httpd.conf file in the CATALINA_HOME/conf directory:

       

      LoadModule jk_module modules/mod_jk.so
      JkWorkersFile <basepath>/Apache2/conf/workers.properties
      JkLogFile D:/Apache/Apache2/logs/mod_jk.log
      # [debug/error/info]
      JkLogLevel error
      JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
      JkRequestLogFormat "%w %V %T"
      JkMount /<app1> loadbalancer
      JkMount /<app1>/* loadbalancer
      JkMount /<app2> loadbalancer
      JkMount /<app2>/* loadbalancer
      # jkstatus
      JkMount /jkstatus jkstatus
      # Deny direct access
      <Location "/<app1>/WEB-INF/">
          AllowOverride None
          deny from all
      </Location>
      <Location "/<app1>/META-INF/">
          AllowOverride None
          deny from all
      </Location>
      <Location "/<app2>/WEB-INF/">
          AllowOverride None
          deny from all
      </Location>
      <Location "/<app2>/META-INF/">
          AllowOverride None
          deny from all
      </Location>

      Where do we enter the above mentioned parameters when we do not have a httpd.conf file? Also, we start our
      tomcat server instance using a script 'startup.sh' laid out in the CATALINA_HOME/bin directory and this
      script in turn calls catalina.sh script to run the tomcat instance.

      2. We also tried to follow the instaructions (which are same as the web link mentioned in the step 1) at
      following link:

      http://community.jboss.org/wiki/UsingModjk12WithJBoss

       

      3. Lets say if we create mod-jk.conf file with the above mentioned settings then where do we include this file, in startup.sh or in catalina.sh and how?

      4. After downloading  mod_jk-1.2.31-httpd-2.0.X.so  library and re-naming it mod_jk.so, where should we place it in the CATALINA_HOME?

      5. Using this mod_jk utility only in our tomcat instances (lets say if we run 4-5 tomcat instances acting as web servers on separate machines) which will in turn talk to a single JBoss server instance (acting as Application Server), can we able to scale our web application to support more concurrent users? Currently, we are trying to increase the number of tomcat instances to scale our web application users? Is it a fair approach without touching single JBoss instance?

      6. After configuring tomcat with mod_jk what other configuration needs to be done on JBoss side?

       

      Please provide your inputs.

       

      Thanks

      Pankaj