English

How To: Configure Apache with Tomcat and the ArcIMS AppServerLink and JSP Samples on Windows

Summary

Instructions provided describe the steps to configure Apache with Tomcat for the ArcIMS AppServerLink and copy the JSP website directories to the correct location.

Procedure

  1. Create a directory structure in your Tomcat installation directory.
    a. Under <Tomcat_home>, create a new directory with the name of your choice, such as “jsp”, under the Webapps directory.
    b. Under this new directory create another directory called WEB-INF.
    c. Under the WEB-INF directory create two directories: lib and classes.
    When creating your applications, all JAR files should go in the lib directory and all expanded JAR files or class files should go in the classes directory.
    Each application, such as a JSP Web site, should be included in a folder at the same level as the WEB-INF directory. A sample directory structure looks like the following:
    <Tomcat_Home>
      |_Webapps
        |_jsp
          |_WEB-INF
            |_lib
              |_JAR files
            |_classes
              |_class files
  2. Create an alias for the directory created in Step 1a:
    a. Open <Apache_home>\conf\httpd.conf in a text editor.
    b. Search for the alias section where you added alias names for Manager, Website, and Output when installing ArcIMS.
    c. Add new aliases pointing to the directory created in Step 1a, for example, jsp. Add the following aliases to the list:
    Code:
    Alias /jsp “C:/<Tomcat_home>/webapps/jsp”
    Alias /JSP “C:/<Tomcat_home>/webapps/jsp”
  3. Set default.jsp as a default page:
    a. Open <Apache_Home>\conf\httpd.conf in a text editor.
    b. Search on DirectoryIndex.
    c. Add default.jsp to the list using a space to separate it from other default page types. Save and close httpd.conf.
    d. Open <Tomcat_home>\conf\web.xml in a text editor.
    e. Search on welcome-file-list.
    f. Add the following to the list under <welcome-file-list>:
    Code:
    <welcome-file>
    	default.jsp
    </welcome-file>

    Save and close web.xml.
  4. Stop and Start Apache and Jakarta.
    -On Windows NT: Click Start > Settings > Control Panel > Services;
    -On Windows 2000: Click Start > Settings > Control Panel > Administrative Tools > Component Services.
  5. Copy the following JAR files to the lib directory located under directory created in Step 1a, for example, jsp:
    <ArcIMS Installation Directory>\Connectors\AppServerLink\arcims_appserverlink.jar
    <ArcIMS Installation Directory>\Samples\Java_JSP\Classes\arcims_jspbeans.jar
  6. Copy the sample ArcIMS JSP Web sites into the directory created in Step 1a, for example, jsp:
    a. <ArcIMS Installation Directory>\Samples\Java_JSP\AdvancedViewer to <Tomcat_home>\webapps\jsp\AdvancedViewer
    b. <ArcIMS Installation Directory>\Samples\Java_JSP\Extractor to <Tomcat_home>\webapps\jsp\Extractor.
    c. <ArcIMS Installation Directory>\Samples\Java_JSP\Geocoder to <Tomcat_home>\webapps\jsp\Geocoder
    When all the files and directories are copied, the Tomcat directory should look something like the following:
    <Tomcat_Home>
      |_Webapps
        |_jsp
          |_WEB-INF
            |_lib
              |_arcims_appserverlink.jar
              |_arcims_jspbeans.jar
            |_classes
              |_(empty)
          |_AdvancedViewer
            |_default.jsp
          |_Extractor
            |_default.jsp
          |_Geocoder
            |_default.jsp
  7. Troubleshooting if default.jsp doesn't work as a default page. The best workaround is to use “index.jsp” instead of “default.jsp” for the default file name:
    a. Open <Apache_Home>\conf\httpd.conf in a text editor. Search on DirectoryIndex. Add index.jsp to the list using a space to separate it from other default page types. Save and close the file.
    b. Restart Apache.
    -On Windows NT: Click Start > Settings > Control Panel > Services;
    -On Windows 2000: Click Start > Settings > Control Panel > Administrative Tools > Component Services.
    c. In each samples directory, rename default.jsp to index.jsp.

Related Information