Set up WAR files for out-of-process ASF Tomcat server with HTTP Server (powered by Apache)

This topic provides information about how to set up a Web Archive (WAR) file for use with the Tomcat servlet engine with the IBM® Web Administration for i5/OS™ interface.

Important: Information for this topic supports the latest PTF levels for HTTP Server for i5/OS . It is recommended that you install the latest PTFs to upgrade to the latest level of the HTTP Server for i5/OS. Some of the topics documented here are not available prior to this update. See http://www.ibm.com/servers/eserver/iseries/software/http/services/service.htm Link outside Information Center for more information.

Follow the instructions to use a WAR file with out-of-process ASF Tomcat servlet engine on your HTTP Server (powered by Apache).

Before you begin, review the User profiles and required authorities for HTTP Server topic.

Configure the out-of-process ASF Tomcat

  1. Click the Manage tab.
  2. Click the ASF Tomcat Servers subtab.
  3. Expand Tomcat Tasks and Wizards.
  4. Click Create ASF Tomcat Server.
  5. Enter a name for your ASF Tomcat server.
  6. Click Next.
  7. Accept the default value (QTMHHTTP) or enter a specific user id for Server userid.
  8. Accept the default value for Java™ version (JDK).
  9. Accept the default value for ASF Tomcat home.
  10. Accept the default value for Java classpath entries.
  11. Click Next.
  12. Accept the default value for IP address.
  13. Enter the port number you provided for your localhost or remote server host for Port.
    Note: If no port number was given (you accepted the default localhost:8009) accept the default value.
  14. Select Binary (AJP13) for Server type.
  15. Click Next.
  16. Click Add.
  17. Enter the name of your WAR file with a forward slash "/" before it for URL path. For example, /warexample.
  18. Enter webapps followed by a forward slash "/" and the name of your WAR file for Application base directory. For example, webapps/warexample.
    Note: Do not select the Reloadable option at this time.
  19. Click Continue

    The WAR file contains a web.xml file. The first time the WAR file is accessed, the files within the WAR file are extracted into the correct directory.

  20. Click Next.
  21. Click Finish.
  22. Click OK.

Configure HTTP Server (powered by Apache) for ASF Tomcat

  1. Start the IBM Web Administration for i5/OS interface.
  2. Click the Manage tab.
  3. Click the HTTP Servers subtab.
  4. Select your HTTP Server (powered by Apache) from the Server list.
  5. Select Global configuration from the Server area list.
  6. Expand Server Properties.
  7. Click ASF Tomcat Setup task from the task list.
  8. Select Enable from Enable servlets fro this HTTP Server.
  9. Accept the default workers definition file for Workers definition file.
  10. Click Next.
  11. Select Enable from Enable "out-of-process" servlet engine connections.
    Note: Do not select the Enable an "in-process" servlet engine option at this time.
  12. Click Add.
  13. Accept the default name or enter a new name of your ASF Tomcat server for Worker name.
    Note: The name of the worker will be used below.
  14. Select Binary (AJP13) for Worker type.
  15. Enter information based off one of the below conditions for Hostname:Port.
    1. Enter localhost and a port number if your out-of-process ASF Tomcat server is on your iSeries™. For example, localhost:8009.
    2. Enter the name of the remote server host and the port number if your out-of-process ASF Tomcat server is not on your local iSeries. For example, IBMiSeries:8009.
  16. Click Continue.
  17. Click Next.
  18. Click Add.
  19. Enter the name of your WAR file with a forward slash "/" before it for URL (Mount point). For example, /warexample.
    Note: This name will be used below.
  20. Accept the default value for ASF Tomcat worker. Select the worker defined by you above.
  21. Click Add.
  22. Enter the name of your WAR file with a forward slash "/" before it and after it, followed by an asterisk "*" for URL (Mount point). For example, /warexample/*.

    This URL (Mount point) is necessary so the files contained in your WAR file can be accessed.

  23. Accept the default value for ASF Tomcat worker.
  24. Click Continue.
  25. Click Next.
  26. Click Finish.
  27. Click OK.

Place your WAR file in the correct directory

Using a file transfer method such as Netserver mapped drives or FTP, transfer the WAR file to the following directory: /ASFTomcat/[myserver]/webapps (where myserver is your server's name).

Start HTTP Server and out-of-process ASF Tomcat server

  1. Click the Manage tab.
  2. Click All Servers subtab.
  3. Click the All HTTP Servers tab.
  4. Select your HTTP Server (powered by Apache) from the table.
  5. Click Start.
  6. Click the All ASF Tomcat Servers tab.
  7. Select your out-of-process ASF Tomcat server from the table.
  8. Click Start.

Test your configuration

  1. Start a Web browser.
  2. Enter http://myserver:port/warexample, where myserver:port is the name of your iSeries and port number and warexample is the name of your WAR file.