2012-07-11

How to install Tomcat and IIS

Summary
  1. Add isapi_redirect.dll on IIS
  2. Add [VirtualDirectory] and set [Enabled] on [HandlerMapping]
    Add [ISAPI Filters] on [Web Site] including the added VirtualDirectory
    Add [ISAPI and CGI Restrictions] on [Server]
    

  3. Configure Tomcat
  4. [isapi_redirect.properties] in [TOMCAT_HOME]/ISAPI
    [workers.properties] and [uriworkermap.properties] in [TOMCAT_HOME]/conf
    

How to install Tomcat and IIS
  1. Install JDK, Tomcat(ex, C:\ApacheTomcat), and place Tomcat connector into [TOMCAT_HOME]\ISAPI

  2. Configure IIS
    1. Add Tomcat into [SVR]-[ISAPI and CGI Restrictions]

    2. Add Tomcat into [SVR]-[Handler Mappings] and check Execute on [Edit Feature Permissions]



    3. [Add Virtual Directory], Its name will be used as [extension_uri] of Tomcat Connector


    4. Add ISAPI Filters


  3. Configure Tomcat
    1. Make sure the next 4 elements at [TOMCAT_HOME]/conf/Server.xml
      <Connector port="8080" protocol="HTTP/1.1“ connectionTimeout="20000” redirectPort="8443" />
      <Connector port="8009" protocol="AJP/1.3" redirectPort="8443" />
      <Host name="localhost"  appBase="webapps” unpackWARs="true" autoDeploy="true“>
      <Context path=" " docBase="C:/Homepage/Tomcat" reloadable="false" />

  4. Configure Tomcat Connector
    1. Make a file [isapi_redirect.properties] with following contents in the folder [TOMCAT_HOME]/ISAPI
      extension_uri=/jakarta/isapi_redirect.dll
      log_file=[TOMCAT_HOME]\logs\isapi_redirect.log
      log_level=info
      worker_file=[TOMCAT_HOME]\conf\workers.properties
      worker_mount_file=[TOMCAT_HOME]\conf\uriworkermap.properties

    2. Make a file [workers.properties] with following contents in the folder [TOMCAT_HOME]/conf
      worker.list=worker1, worker2
      worker.worker1.host=localhost
      worker.worker1.port=8009
      worker.worker1.type=ajp13
      #worker.worker2.host=otherhost
      #worker.worker2.port=8009
      #worker.worker2.type=ajp13
      

    3. Make a file [uriworkermap.properties] with following contents in the folder [TOMCAT_HOME]/conf
      /*.jsp=worker1
      /fedex/*=worker1

No comments:

Post a Comment