You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by da...@apache.org on 2001/02/01 17:52:26 UTC

cvs commit: jakarta-tomcat/src/doc/uguide tomcat_ug.html

danmil      01/02/01 08:52:26

  Modified:    src/doc  Tag: tomcat_32 tomcat-ssl-howto.html
                        tomcat-apache-howto.html
               src/doc/uguide Tag: tomcat_32 tomcat_ug.html
  Log:
  Cleaned up HTML, fixed typos.
  
  Contributed by Chris Pepper <pe...@reppep.com>
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +194 -141  jakarta-tomcat/src/doc/tomcat-ssl-howto.html
  
  Index: tomcat-ssl-howto.html
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat/src/doc/tomcat-ssl-howto.html,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -r1.1.2.2 -r1.1.2.3
  --- tomcat-ssl-howto.html	2000/12/11 17:13:30	1.1.2.2
  +++ tomcat-ssl-howto.html	2001/02/01 16:52:21	1.1.2.3
  @@ -1,3 +1,4 @@
  +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
   <html>
   <head>
       <!-- $Id  $ -->
  @@ -45,41 +46,61 @@
       </td>
     </tr>
   </table>
  +
   <h1>Tomcat and SSL</h1>
  -<p>By Gomez Henri <tt>&lt;<a href="mailto:shachor@il.ibm.com">hgomez@slib.fr</a>&gt;</tt></p>
  +
  +<p>By Gomez Henri <tt>&lt;<a href="mailto:hgomez@slib.fr">hgomez@slib.fr</a>&gt;</tt></p>
  +
   <h2>Table of Contents</h2>
  +
   <ul>
     <li><a href="#s2">Tomcat and SSL</a></li>
     <li><a href="#s3">Building tomcat with SSL support</a></li>
     <li><a href="#s4">Tomcat with Apache and mod_jk</a></li>
  -  <li><a href="#s5">SSL via apache</a></li>
  -  <li><a href="#s6">SSL direct</a></li>
  +  <li><a href="#s5">SSL via Apache</a></li>
  +  <li><a href="#s6">Direct SSL</a></li>
     <li><a href="#s7">Credits</a></li>
   </ul>
  +
   <hr>
  +
   <h2><a name=s2>Tomcat and SSL</a></h2>
  -<p>Tomcat could use SSL directly (via an HTTP connector supporting SSL) or via 
  -  an Apache SSLified (<a href="http://www.apachessl.org">Apache-SSL</a> or apache-mod_ssl) 
  +
  +<p>Tomcat can use SSL directly (via an HTTP connector supporting SSL) or via 
  +  an SSL-capable Apache (<a
  +  href="http://www.apachessl.org">Apache-SSL</a> or <a
  +  href="http://www.modssl.org">apache+mod_ssl</a>) 
     with the mod_jk connector.</p>
  +
   <hr>
  +
   <h2><a name=s3>Building tomcat with SSL support</a></h2>
  -<p>If you want to rebuild the tomcat with SSL, be carefull of your CLASSPATH. 
  -  I used to clear the CLASSPATH env var to avoid conflict in jar. A common case 
  -  of conflict is for XML parsers (xerces & jaxp). tomcat need a recent XML parser 
  -  like Apache Group xerces 1.1.2 or Sun's jaxp 1.0.1.</p>
  -<p>At build time, (via ant), tomcat will check for some libs and will then included 
  -  more or less options. It's the case of SSL support. If you have the JSSE 1.0.2 
  -  jars in your CLASSPATH, tomcat will be built with SSL (SSLSocketFactory). tomcat 
  -  will use the JSSE jars (jcert.jar, jsse.jar, jnet.jar).This software COULDN'T 
  -  BE INCLUDED in tomcat. You'll have to go to <a href="http://java.sun.com/products/jsse/%20">jsse 
  -  home page </a>and download from there the domestic (US/Canada) or global archive. 
  -  Then copy the 3 jars in tomcat runtime classpath lib ($TOMCAT_HOME/lib).</p>
  +
  +<p>If you want to rebuild tomcat with SSL, be careful of your
  +  CLASSPATH. I used to clear the CLASSPATH environment variable to avoid
  +  conflict in jar. A common cause of conflict is XML parsers (xerces
  +  &amp; jaxp). Tomcat needs a recent XML parser like the Apache Group's
  +  xerces 1.1.2 or Sun's jaxp 1.0.1.</p>
  +<p>At build time, (via ant), tomcat will check for some libs and will
  +  then include various options, possibly including SSL support. If you
  +  have the JSSE 1.0.2 jars in your CLASSPATH, tomcat will be built with
  +  SSL (SSLSocketFactory). Tomcat will use the JSSE jars (jcert.jar,
  +  jsse.jar, jnet.jar). This software COULDN'T BE INCLUDED in tomcat.
  +  You'll have to go to the <a
  +  href="http://java.sun.com/products/jsse/">jsse home page</a> and
  +  download the domestic (US/Canada) or global archive from there. Then
  +  copy the 3 jars into tomcat's runtime classpath lib
  +  ($TOMCAT_HOME/lib).</p>
  +
   <hr>
  +
   <h2><a name=s4>Tomcat with Apache and mod_jk</a></h2>
  -<p>If you use Apache with SSL (apache-ssl or apache-mod_ssl), the apache connector 
  -  mod_jk will be able to forward to tomcat some SSL informations if JkExtractSSL 
  -  directive is present in your httpd.conf. </p>
  -<p>Informations are :</p>
  +
  +<p>If you use Apache with SSL (Apache-SSL or apache+mod_ssl) and the 
  +  JkExtractSSL directive in httpd.conf, the apache connector 
  +  mod_jk will be able to pass some SSL information to tomcat.</p>
  +<p>This information is:</p>
  +
   <table width="75%" border="1">
     <tr> 
       <td>HTTPS</td>
  @@ -98,8 +119,10 @@
       <td>SSL Certificate of client</td>
     </tr>
   </table>
  -<p>Since apache-ssl and apache-mod_ssl use differents env vars, you could adapt 
  -  SSL vars via the following JK vars </p>
  +
  +<p>Since Apache-SSL and apache+mod_ssl use different environment variables, you 
  +  can set SSL variables from the following JK variables</p>
  +
   <ul>
     <li>JkExtractSSL</li>
     <li>JkHTTPSIndicator</li>
  @@ -107,153 +130,182 @@
     <li>JkCIPHERIndicator</li>
     <li>JkCERTSIndicator: </li>
   </ul>
  -<p>here is an example of directive to include in httpd.conf for use with mod_ssl 
  -</p>
  -<p><font face="Courier New, Courier, mono" size="-1"># Should mod_jk send SSL 
  -  information to Tomact (default is On)<br>
  -  JkExtractSSL On <br>
  -  # What is the indicator for SSL (default is HTTPS)<br>
  -  JkHTTPSIndicator HTTPS <br>
  -  # What is the indicator for SSL session (default is SSL_SESSION_ID) <br>
  -  JkSESSIONIndicator SSL_SESSION_ID <br>
  -  # What is the indicator for client SSL cipher suit (default is SSL_CIPHER) <br>
  -  JkCIPHERIndicator SSL_CIPHER <br>
  -  # What is the indicator for the client SSL certificated (default is SSL_CLIENT_CERT) 
  -  <br>
  -  JkCERTSIndicator SSL_CLIENT_CERT </font></p>
  -<p>When using mod_jk with Apache & mod_ssl it is essential to specify "SSLOptions 
  -  +StdEnvVars +ExportCertData" in the httpd.conf file.<br>
  -  Otherwise mod_ssl will not produce the neccessary environment variables for 
  +
  +<p>here is an example of directives to include in httpd.conf for use with
  +  mod_ssl:</p>
  +
  +<pre># Should mod_jk send SSL information to Tomcat (default is On)
  +JkExtractSSL On
  +# What is the indicator for SSL (default is HTTPS)
  +JkHTTPSIndicator HTTPS
  +# What is the indicator for SSL session (default is SSL_SESSION_ID)
  +JkSESSIONIndicator SSL_SESSION_ID
  +# What is the indicator for client SSL cipher suit (default is SSL_CIPHER)
  +JkCIPHERIndicator SSL_CIPHER
  +# What is the indicator for the client SSL certificated (default is SSL_CLIENT_CERT)
  +JkCERTSIndicator SSL_CLIENT_CERT
  +</pre>
  +
  +<p>When using mod_jk with Apache &amp; mod_ssl it is essential to specify 
  +  "SSLOptions +StdEnvVars +ExportCertData" in the httpd.conf file.<br>
  +  Otherwise mod_ssl will not produce the necessary environment variables for 
     mod_jk. (Tilo Christ &lt;tilo.christ@med.siemens.de&gt;)</p>
  -<p>Warning, even if mod_jk support both ajp12 (old version from ApacheJServ) and 
  -  ajp13, only ajp13 could forward SSL informations to tomcat.</p>
  +<p>Warning: Even if mod_jk supports both ajp12 (the old version from
  +  Apache JServ) and ajp13, only ajp13 can forward SSL information to
  +  tomcat.</p>
  +
   <hr>
  -<h2><a name=s5>SSL via apache</a></h2>
  -<p>mod_jk seems to support the VirtualHost directive of Apache. It's specialy 
  -  usefull when using an apache-mod_ssl with tomcat.<br>
  +
  +<h2><a name=s5>SSL via Apache</a></h2>
  +
  +<p>mod_jk seems to support the VirtualHost directive of Apache. It's especially 
  +  useful when using apache+mod_ssl with tomcat.<br>
     This config will easily secure your webapps via Apache SSL support. Just take 
  -  care of setting these jk vars outside VirtualHost directives :</p>
  -<p> <font face="Courier New, Courier, mono" size="-1">JkWorkersFile /etc/httpd/conf/workers.properties<br>
  -  JkLogFile /var/log/httpd/mod_jk.log <br>
  -  JkLogLevel warn</font> </p>
  -<p>The jk redirect stuff could be set in virtual hosts : <virtualhost _default_:443></p>
  -<p><font face="Courier New, Courier, mono" size="-1">&lt;VirtualHost _default_:443&gt;<br>
  -  SSLEngine on <br>
  -  SSLCipherSuite ALL:!ADH:!EXP56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL 
  -  <br>
  -  <br>
  -  </font><font face="Courier New, Courier, mono" size="-1"># other SSL stuff<br>
  -  </font><font face="Courier New, Courier, mono" size="-1"><br>
  -  Alias /alesia "/var/tomcat/webapps/alesia" <directory "/var/tomcat/webapps/alesia"> 
  -  <br>
  -  &lt;Directory "/var/tomcat/webapps/alesia"&gt;</directory><br>
  -  <directory "/var/tomcat/webapps/alesia">Options Indexes FollowSymLinks </directory> 
  -  <br>
  -  &lt;/Directory> <br>
  -  <br>
  -  JkMount /alesia/servlet/* ajp13 <br>
  -  JkMount /alesia/*.jsp ajp13 <location "/alesia/WEB-INF/"><br>
  -  </location><br>
  -  &lt;Location "/alesia/WEB-INF/"><br>
  -  AllowOverride None<br>
  -  Deny from all<br>
  -  &lt;/Location> </font></p>
  -<p><font face="Courier New, Courier, mono" size="-1">&lt;/VirtualHost></font><virtualhost _default_:443></virtualhost></p>
  +  care of setting these JK variables outside VirtualHost directives:</p>
  +
  +<pre>JkWorkersFile /etc/httpd/conf/workers.properties
  +JkLogFile /var/log/httpd/mod_jk.log
  +JkLogLevel warn
  +</pre>
  +
  +<p>The JK redirect stuff could be set in virtual hosts: &lt;virtualhost
  +  _default_:443&gt;</p>
  +
  +<pre>&lt;VirtualHost _default_:443&gt;
  +SSLEngine on
  +SSLCipherSuite ALL:!ADH:!EXP56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL 
  +# other SSL stuff
  +Alias /alesia "/var/tomcat/webapps/alesia"
  +
  +&lt;Directory "/var/tomcat/webapps/alesia"&gt; 
  +  &lt;Directory "/var/tomcat/webapps/alesia"&gt;&lt;/Directory&gt;
  +  &lt;Directory "/var/tomcat/webapps/alesia"&gt;Options Indexes FollowSymLinks &lt;/Directory&gt;
  +&lt;/Directory&gt;
  +
  +JkMount /alesia/servlet/* ajp13
  +JkMount /alesia/*.jsp ajp13
  +
  +&lt;Location "/alesia/WEB-INF/"&gt;
  +&lt;/Location&gt;
  +
  +&lt;Location "/alesia/WEB-INF/"&gt;
  +  AllowOverride None
  +  Deny from all
  +&lt;/Location&gt;
  +
  +&lt;/VirtualHost&gt;
  +<!--
  +
  +&lt;virtualhost _default_:443&gt;&lt;/virtualhost&gt;
  +-->
  +</pre>
  +
   <hr>
  -<h2><a name=s6>SSL direct</a></h2>
  -<p>If you want tomcat run HTTP/SSL, you need to create a SSL certificate. For 
  -  more informations about SSL and certificates, I suggest you could take a look 
  -  at <a href="http://www.openssl.org">OpenSSL</a> (OpenSource SSL implementation) 
  -  and <a href="http://www.modssl.org">ModSSL</a> (SSL support for Apache)</p>
  -<h3><a name=s61><font size="+1">Verify tomcat server.xml configuration file</font></a></h3>
  +
  +<h2><a name=s6>Direct SSL</a></h2>
  +
  +<p>If you want tomcat to serve HTTP/SSL (https) directly, you need to 
  +  create a SSL certificate. For more information about SSL and 
  +  certificates, I suggest you could take a look at <a 
  +  href="http://www.openssl.org">OpenSSL</a> (Open Source SSL
  +  implementation) and <a href="http://www.modssl.org">mod_ssl</a> (SSL
  +  support for Apache)</p>
  +
  +<h3><a name=s61><font size="+1">Verify tomcat server.xml configuration
  +  file</font></a></h3>
  +
   <blockquote> 
     <p> To use the HTTP with SSL connector in tomcat, verify that it is activated 
       in server.xml</p>
  -  <p><font face="Courier New, Courier, mono" size="-1">&lt;Connector className="org.apache.tomcat.service.PoolTcpConnector"&gt;<br>
  -    &lt;Parameter name="handler" value="org.apache.tomcat.service.http.HttpConnectionHandler"/&gt;<br>
  -    &lt;Parameter name="port" value="8443"/&gt;<br>
  -    &lt;Parameter name="socketFactory" value="org.apache.tomcat.net.SSLSocketFactory" 
  -    /&gt;<br>
  -    &lt;Parameter name="keystore" value="/var/tomcat/conf/keystore" /&gt;</font><font face="Courier New, Courier, mono" size="-1"> 
  -    <br>
  -    &lt;Parameter name="keypass" value="changeit"/&gt;<br>
  -    &lt;Parameter name="clientAuth" value="true"/&gt; <br>
  -    &lt;/Connector&gt; </font></p>
  -  <p>In this example we indicate the keystore is file <b>/var/tomcat/conf/keystore</b>. 
  -    The keystore password is <b>changeit</b> and we want client to authentificate.</p>
  -  <blockquote>&nbsp;</blockquote>
  +
  +<pre>&lt;Connector className="org.apache.tomcat.service.PoolTcpConnector"&gt;
  +&lt;Parameter name="handler" value="org.apache.tomcat.service.http.HttpConnectionHandler"/&gt;
  +&lt;Parameter name="port" value="8443"/&gt;
  +&lt;Parameter name="socketFactory" value="org.apache.tomcat.net.SSLSocketFactory"/&gt;
  +&lt;Parameter name="keystore" value="/var/tomcat/conf/keystore" /&gt;
  +&lt;Parameter name="keypass" value="changeit"/&gt;
  +&lt;Parameter name="clientAuth" value="true"/&gt;
  +&lt;/Connector&gt;
  +</pre>
  +
  +<p>In this example we indicate the keystore is file
  +  <strong>/var/tomcat/conf/keystore</strong>. 
  +    The keystore password is <strong>changeit</strong> and we want
  +    clients to authentificate.</p>
   </blockquote>
  +
   <h3><a name=s62>Generate a SSL certificate (RSA) for tomcat</a></h3>
  +
   <blockquote>
  -  <p>I succeed (at least) with my IBM JDK 1.3 after : </p>
  +  <p>I succeed (at least) with my IBM JDK 1.3 after:</p>
   </blockquote>
  +
   <ul>
  -  <li> jsse jars <b>MUST BE IN BOTH CLASSPATH</b> and <b>$JAVA_HOME/jre/lib/ext 
  -    (JAVA &gt; 1.2)<br>
  -    </b><br>
  +  <li>jsse jars <strong>MUST BE IN BOTH CLASSPATH</strong> and
  +    <strong>$JAVA_HOME/jre/lib/ext 
  +    (JAVA &gt; 1.2)</strong>
     </li>
  -  <li> from server.xml doc.You _need_ to set up a server certificate if you want 
  -    this to work, and you need JSSE. <br>
  -    <br>
  +  <li>from server.xml doc.You _need_ to set up a server certificate if you want 
  +    this to work, and you need JSSE.
       <ul>
  -      <li> Add JSSE jars to CLASSPATH </li>
  -      <li> Edit $JAVA_HOME/jre/lib/security/java.security Add: security.provider.2=com.sun.net.ssl.internal.ssl.Provider</li>
  -      <li> Do: <font face="Courier New, Courier, mono" size="-1">keytool -genkey 
  -        -alias tomcat -keyalg RSA</font> RSA is essential to work with Netscape 
  -        and IIS. Use "changeit" as password. ( or add keypass attribute ) You 
  +      <li>Add JSSE jars to CLASSPATH</li>
  +      <li>Edit $JAVA_HOME/jre/lib/security/java.security<br>
  +      	Add: security.provider.2=com.sun.net.ssl.internal.ssl.Provider</li>
  +      <li>Do: <code>keytool -genkey -alias tomcat -keyalg RSA</code><br>
  +      	RSA is essential to work with Netscape 
  +        and IIS. Use "changeit" as password (or add keypass attribute). You 
           don't need to sign the certificate. You can set parameter keystore and 
  -        keypass if you want to change the default ( user.home/.keystore with changeit 
  -        )<br>
  -        <br>
  -      </li>
  +        keypass if you want to change the default
  +        ($HOME/.keystore with changeit)</li>
       </ul>
     </li>
  -  <li> I suggest you install jcert.jar, jnet.jar and jsse.jar in $JAVA_HOME/jre/lib/ext 
  -    and then add them to CLASSPATH export <br>
  -    <br>
  -    <font size="-1" face="Courier New, Courier, mono">CLASSPATH=$JAVA_HOME/jre/lib/ext/jcert.jar:$CLASSPATH 
  -    export CLASSPATH=$JAVA_HOME/jre/lib/ext/jnet.jar:$CLASSPATH export CLASSPATH=$JAVA_HOME/jre/lib/ext/jsse.jar:$CLASSPATH</font><br>
  +  <li>I suggest you install jcert.jar, jnet.jar and jsse.jar in
  +    $JAVA_HOME/jre/lib/ext 
  +    and then add them to your CLASSPATH export <br>
       <br>
  -    You could also copy the 3 jars in $TOMCAT_HOME/lib/ so there are automatically 
  -    added to CLASSPATH at tomcat startup (tomcat.sh).</li>
  +
  +<pre>CLASSPATH=$JAVA_HOME/jre/lib/ext/jcert.jar:$CLASSPATH 
  +export CLASSPATH=$JAVA_HOME/jre/lib/ext/jnet.jar:$CLASSPATH
  +export CLASSPATH=$JAVA_HOME/jre/lib/ext/jsse.jar:$CLASSPATH
  +</pre>
  +
  +    You could also copy the 3 jars into $TOMCAT_HOME/lib/ so they are 
  +    under the existing CLASSPATH at tomcat startup (tomcat.sh).</li>
   </ul>
  -<p>&nbsp; </p>
  +
   <h3><a name=s63>Importing SSL certificates</a></h3>
  -<p>It's possible to import certificates generated with <a href="http://www.openssl.org">OpenSSL</a>. 
  -  Here are the steps needed to generate such certs with OpenSSL : </p>
  +
  +<p>It's possible to import certificates generated with <a
  +  href="http://www.openssl.org">OpenSSL</a>. Here are the steps needed 
  +  to generate such certs with OpenSSL:</p>
  +
   <ul>
  -  <li>To generate a new request and a new key <br>
  -    <pre><font face="Courier New, Courier, mono">openssl req -new -out REQ.pem -keyout KEY.pem</font> </pre>
  -  </li>
  +  <li>To generate a new request and a new key<br>
  +	<code>openssl req -new -out REQ.pem -keyout KEY.pem</code></li>
     <li>To generate a self signed x509 certificate from a certificate request using 
  -    a supplied key, and we want to see the text form of the output certificate 
  -    (which we will put in the file selfSign.pem 
  -    <p><font face="Courier New, Courier, mono" size="-1">openssl req -x509 -in 
  -      REQ.pem -key KEY.pem -out CERT.pem</font> </p>
  -  </li>
  -  <li>Verify that the signature is correct on a certificate request. 
  -    <p><font face="Courier New, Courier, mono" size="-1">openssl req -verify -in 
  -      REQ.pem</font> </p>
  -  </li>
  -  <li>Verify that the signature was made using a specified public key 
  -    <p><font face="Courier New, Courier, mono" size="-1">openssl req -verify -in 
  -      REQ.pem -key KEY.pem</font> </p>
  -  </li>
  -  <li>Print the contents of a certificate request 
  -    <p><font face="Courier New, Courier, mono" size="-1">openssl req -text -in 
  -      REQ.pem</font> </p>
  -  </li>
  -  <li>To import the CERT in keystore, you just do next : 
  -    <p><font face="Courier New, Courier, mono" size="-1">keytool -import -v -trustcacerts 
  -      -alias tomcat -file</font> <font size="-1" face="Courier New, Courier, mono">CERT.pem</font> 
  -    </p>
  -  </li>
  +    a supplied key, and see the text form of the output certificate 
  +    (which we will put into the file selfSign.pem<br>
  +	<code>openssl req -x509 -in REQ.pem -key KEY.pem -out
  +	CERT.pem</code></li>
  +  <li>Verify that the signature is correct on a certificate request.<br>
  +	<code>openssl req -verify -in REQ.pem</code></li>
  +  <li>Verify that the signature was made using a specified public key<br>
  +	<code>openssl req -verify -in REQ.pem -key KEY.pem</code></li>
  +  <li>Print the contents of a certificate request<br>
  +	<code>openssl req -text -in REQ.pem</code></li>
  +  <li>To import the CERT in keystore, just:<br>
  +	<code>keytool -import -v -trustcacerts -alias tomcat -file
  +	CERT.pem</code></li>
   </ul>
  +
   <hr>
  +
   <h2><a name=s7>Credits</a></h2>
  +
   <p>This document was created by <a href="mailto:hgomez@slib.fr">Gomez Henri</a>. 
     Thanks to hgopal@cmcltd.com for import info. Feel free to contact me for more 
     updates.</p>
  +
   <table width="100%" border="0" cellpadding="10" cellspacing="0">
     <tr> 
       <td> 
  @@ -265,6 +317,7 @@
       </td>
     </tr>
   </table>
  +
   </body>
   </html>
   
  
  
  
  1.2.2.3   +50 -44    jakarta-tomcat/src/doc/tomcat-apache-howto.html
  
  Index: tomcat-apache-howto.html
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat/src/doc/tomcat-apache-howto.html,v
  retrieving revision 1.2.2.2
  retrieving revision 1.2.2.3
  diff -u -r1.2.2.2 -r1.2.2.3
  --- tomcat-apache-howto.html	2000/10/05 06:37:52	1.2.2.2
  +++ tomcat-apache-howto.html	2001/02/01 16:52:21	1.2.2.3
  @@ -1,6 +1,7 @@
  +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
   <html>
     <head>
  -    <!-- $Id: tomcat-apache-howto.html,v 1.2.2.2 2000/10/05 06:37:52 larryi Exp $ -->
  +    <!-- $Id: tomcat-apache-howto.html,v 1.2.2.3 2001/02/01 16:52:21 danmil Exp $ -->
       <!-- Copyright 1999, Apache Software Foundation -->
       <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
       <link rel="stylesheet" href="uguide/style.css">
  @@ -141,19 +142,22 @@
       <h4><a name="work_together">How will they work together?</a></h4>
   
         <blockquote>
  -    <p> In a nutshell a web server is waiting for requests.&nbsp; When these requests arrive the server does whatever is needed to 
  +    <p> In a nutshell a web server is waiting for requests.&nbsp; When
  +    these requests arrive the server does whatever is needed to 
           serve the requests by providing the necessary content.&nbsp; Adding
       Tomcat to the mix may somewhat change this behavior.&nbsp; Now the web 
           server needs to perform the following:
       <ul>
         <li> Before the first request can be served, Apache needs to load a web
  -        server adapter (how Tomcat will communicate w/Apache) library and initialize it. </li>
  -      <li> When a request arrives, Apache needs to check and see if it belongs to a servlet, if so it needs to let the adapter
  +           server adapter library (so Tomcat can communicate with Apache)
  +           and initialize it. </li>
  +      <li> When a request arrives, Apache needs to check and see if it
  +           belongs to a servlet; if so it needs to let the adapter
              take the request and handle it.</li>
       </ul>
   
       <p>We'd like Apache to handle our static content, such as
  -    images and html documents, and to forward all requests for
  +    images and HTML documents, and forward all requests for
       dynamic content to Tomcat.&nbsp; More specifically, we need answers to the following questions:</p>
   
           <blockquote>
  @@ -227,14 +231,18 @@
         </p>
   
       <blockquote>
  -      <p class="code">    &lt;servlet><br>
  -      &nbsp;&nbsp;&nbsp; &lt;servlet-name&gt;SlifkaWorld&lt;/servlet-name><br>
  -      &nbsp;&nbsp;&nbsp; &lt;servlet-class&gt;foo.bar.baz.SomeClass&lt;/servlet-class><br>
  -      &nbsp;&nbsp;&nbsp; &lt;init-param><br>
  -      &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;param-name&gt;someParameter&lt;/param-name&gt;<br>
  -      &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;param-value&gt;A value&lt;/param-value&gt;<br>
  -      &nbsp;&nbsp;&nbsp; &lt;/init-param><br>
  -    &lt;/servlet>
  +      <p class="code">    &lt;servlet&gt;<br>
  +      &nbsp;&nbsp;&nbsp;
  +          &lt;servlet-name&gt;SlifkaWorld&lt;/servlet-name&gt;<br>
  +      &nbsp;&nbsp;&nbsp;
  +          &lt;servlet-class&gt;foo.bar.baz.SomeClass&lt;/servlet-class&gt;<br>
  +      &nbsp;&nbsp;&nbsp; &lt;init-param&gt;<br>
  +      &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  +          &lt;param-name&gt;someParameter&lt;/param-name&gt;<br>
  +      &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  +          &lt;param-value&gt;A value&lt;/param-value&gt;<br>
  +      &nbsp;&nbsp;&nbsp; &lt;/init-param&gt;<br>
  +    &lt;/servlet&gt;
         </p>
   
       </blockquote>
  @@ -327,13 +335,15 @@
   
           <blockquote>
             <p class="code">&lt;!-- Apache AJP12 support. This is also used to shut down tomcat.
  -          --><br>
  -        &lt;Connector className="org.apache.tomcat.service.PoolTcpConnector"><br>
  +          --&gt;<br>
  +        &lt;Connector
  +            className="org.apache.tomcat.service.PoolTcpConnector"&gt;<br>
             &nbsp;&nbsp;&nbsp; &lt;Parameter name="handler"<br>
  -          &nbsp;&nbsp;&nbsp;&nbsp; value="org.apache.tomcat.service.connector.Ajp12ConnectionHandler"/><br>
  +          &nbsp;&nbsp;&nbsp;&nbsp;
  +              value="org.apache.tomcat.service.connector.Ajp12ConnectionHandler"/&gt;<br>
             &nbsp;&nbsp;&nbsp; &lt;Parameter name="port"<br>
  -          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;value="8007"/><br>
  -        &lt;/Connector></p>
  +          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;value="8007"/&gt;<br>
  +        &lt;/Connector&gt;</p>
   
           </blockquote>
           <p>To ensure that it is indeed listening on that port, Telnet to it or
  @@ -541,7 +551,6 @@
         <blockquote>
           <p>For now, refer to the comments in the mod_jk.conf-auto file and
           <a href="mod_jk-howto.html">mod_jk HOWTO</a> for details.</p>
  -    </p>
   
         </blockquote>
         <h4><a name="httpd_jserv">tomcat-apache.conf</a>
  @@ -786,15 +795,15 @@
           following snippet from server.xml in our AJP section:</p>
           <blockquote>
             <p class="code">&lt;!-- Apache AJP12 support. This is also used to shut down tomcat.
  -          --><br>
  +          --&lt;<br>
           &lt;Connector className=&quot;org.apache.tomcat.service.PoolTcpConnector&quot;&gt;<br>
             &nbsp;&nbsp;&nbsp; &lt;Parameter name="handler"&nbsp;<br>
             &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  -          value="org.apache.tomcat.service.connector.Ajp12ConnectionHandler"/><br>
  +          value="org.apache.tomcat.service.connector.Ajp12ConnectionHandler"/&gt;<br>
             &nbsp;&nbsp;&nbsp; &lt;Parameter name="port"<br>
             &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  -          value="8007"/><br>
  -        &lt;/Connector></p>
  +          value="8007"/&gt;<br>
  +        &lt;/Connector&gt;</p>
           </blockquote>
           <p>The key here is that each port parameter's &quot;value&quot;
           attribute must have a different value.&nbsp; To keep in sync, let's
  @@ -1094,13 +1103,13 @@
         8080.&nbsp; If you examine the supplied server.xml file, you'll see the
         following element:</p>
         <blockquote>
  -      <p class="code">        &lt;!-- Normal HTTP --><br>
  +      <p class="code">        &lt;!-- Normal HTTP --&gt;<br>
           &lt;Connector className=&quot;org.apache.tomcat.service.PoolTcpConnector&quot;&gt;<br>
         &nbsp;&nbsp;&nbsp; &lt;Parameter name="handler"&nbsp;<br>
         &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; value=&quot;org.apache.tomcat.service.http.HttpConnectionHandler&quot;/&gt;<br>
         &nbsp;&nbsp;&nbsp; &lt;Parameter name="port"&nbsp;<br>
  -      &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; value="8080"/><br>
  -        &lt;/Connector></p>
  +      &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; value="8080"/&gt;<br>
  +        &lt;/Connector&gt;</p>
         </blockquote>
         <p>To disable this, just comment out the entire &lt;Connector&gt;
         element.&nbsp; Otherwise, just change it to a port that doesn't conflict
  @@ -1201,28 +1210,25 @@
         to Apache/Tomcat</a>
           </h4>
         <blockquote>
  -      <p>Tomcat doesn't support JSSI Until someone writes an Interceptor to
  +      <p>Tomcat doesn't support JSSI. Until someone writes an Interceptor to
         handle them, the easiest way is to convert your .jhtml files to .jsp
         files.&nbsp; Just replace:
           </p>
  -        <font SIZE="2">
           <blockquote>
  -          <p class="code">&lt;servlet name=myServlet&gt;<br>
  +          <p class="code"><font SIZE="2">&lt;servlet name=myServlet&gt;<br>
             &nbsp;&nbsp;&nbsp; &lt;param name=aParam value=aValue&gt;<br>
  -          &lt;/servlet&gt;</p>
  +          &lt;/servlet&gt;</font></p>
           </blockquote>
  -        </font>
         <p>with
           </p>
  -        <font SIZE="2">
           <blockquote>
  -          <p class="code">&lt;jsp:include page=&quot;/servlet/myServlet&quot;
  +          <p class="code"><font
  +          SIZE="2">&lt;jsp:include page=&quot;/servlet/myServlet&quot;
             flush=&quot;true&quot; &gt;<br>
  -          &nbsp;&nbsp;&nbsp;</font> <font SIZE="2">&lt;jsp:param name=&quot;aParam&quot;
  +          &nbsp;&nbsp;&nbsp; &lt;jsp:param name=&quot;aParam&quot;
             value=&quot;aValue&quot; /&gt;<br>
  -          &lt;/jsp:include&gt;</p>
  +          &lt;/jsp:include&gt;</font></p>
           </blockquote>
  -        </font>
         </blockquote>
         <h4><a name="error_rewrite_usedto">mod_rewrite - Used to work fine with
         Apache/JServ, what gives?</a>
  @@ -1306,14 +1312,14 @@
         off into a separate document and revised by Rob Slifka and Mike Bremford.&nbsp;
       Contributors, listed in alphabetical order:
       <ul>
  -     Jonathan Bnayahu<br>
  -     Mike Bremford<br>
  -     Alex Chaffee<br>
  -     Fiona Czuczman<br>
  -     Costin Manolache<br>
  -     Craig R. McClanahan<br>
  -     Rob Slifka<br>
  -     ...the countless many on the tomcat-dev and tomcat-user lists!
  +     <li>Jonathan Bnayahu<br>
  +     <li>Mike Bremford<br>
  +     <li>Alex Chaffee<br>
  +     <li>Fiona Czuczman<br>
  +     <li>Costin Manolache<br>
  +     <li>Chris Pepper<br>
  +     <li>Rob Slifka<br>
  +     <li>...the countless many on the tomcat-dev and tomcat-user lists!
       </ul>
   
       <table width="100%" border="0" cellpadding="10" cellspacing="0">
  
  
  
  No                   revision
  
  
  No                   revision
  
  
  1.8.2.4   +164 -134  jakarta-tomcat/src/doc/uguide/Attic/tomcat_ug.html
  
  Index: tomcat_ug.html
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat/src/doc/uguide/Attic/tomcat_ug.html,v
  retrieving revision 1.8.2.3
  retrieving revision 1.8.2.4
  diff -u -r1.8.2.3 -r1.8.2.4
  --- tomcat_ug.html	2000/10/16 02:12:20	1.8.2.3
  +++ tomcat_ug.html	2001/02/01 16:52:24	1.8.2.4
  @@ -1,7 +1,7 @@
  -
  +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
   <html>
     <head>
  -    <!-- $Id: tomcat_ug.html,v 1.8.2.3 2000/10/16 02:12:20 larryi Exp $ -->
  +    <!-- $Id: tomcat_ug.html,v 1.8.2.4 2001/02/01 16:52:24 danmil Exp $ -->
       <!-- Copyright 1999, Apache Software Foundation -->
       <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
       <link rel="stylesheet" href=style.css>
  @@ -11,12 +11,13 @@
     </head>
     <body link="#0000ff" vlink="#800080">
       <!-- Banner element, all hail the Project! -->
  + 
       <table border="0" width="100%" cellspacing="0" cellpadding="0">
         <tr>
           <td width="50%">
             <p align="left">
               <a href="http://jakarta.apache.org/index.html">
  -              <img src=images/banner.gif 
  +              <img src="images/banner.gif"
                      width="350" 
                      height="100" 
                      alt="The Jakarta Project" 
  @@ -31,8 +32,9 @@
       </table>
       
       <H1>Tomcat - A Minimalistic User's Guide</H1>
  +
       <p>This document provides some basic information about Tomcat. Some of
  -      the topics covered here are:
  +      the topics covered here are:</p>
   
       <ol>
         <li>The installation of the Tomcat binary version. </li>
  @@ -44,7 +46,7 @@
         <li>An explanation on how to deploy Tomcat on a real web site.</li>
       </ol>
   
  -    Hopefully this should be enough for any new user to get started
  +    <p>Hopefully this should be enough for any new user to get started
       with Tomcat. <a name="where_help">If something is missing then try (in this order):</a></p>
       <ol>
         <li>Search the Tomcat <a href="http://jakarta.apache.org/jyve-faq/Turbine/screen/MainMenu/faq_id/12/project_id/2/screen/DisplayTopics/action/SetAll">faq</a>.</li>      
  @@ -130,19 +132,21 @@
       <a HREF="http://jakarta.apache.org/downloads/binindex.html">
         http://jakarta.apache.org/downloads/binindex.html</a>.
       
  -      <li>Unzip the file into some directory (say foo). This
  -    should create a new subdirectory named "tomcat".
  +      <li>Unpack the file into some directory (say foo). This
  +    should create a new subdirectory named "jakarta-tomcat-3.2.1".
  +    If it's not where you want it, move this directory to the desired
  +    location.
       
  -    <li>Change directory to "tomcat" and set a new environment
  +    <li>Change directory to "jakarta-tomcat-3.2.1" and set a new environment
           variable (TOMCAT_HOME) to point to the root directory of your 
           Tomcat hierarchy.
           <ol>
               <li>On Win32 you should type: <br>
  -                "set TOMCAT_HOME=foo\tomcat" </li>
  +                "set TOMCAT_HOME=foo\jakarta-tomcat-3.2.1" </li>
           
               <li>On UNIX you should type: <br>
  -                for bash/sh "TOMCAT_HOME=foo/tomcat ; export TOMCAT_HOME"<br>
  -                for tcsh "setenv TOMCAT_HOME foo/tomcat"</li>
  +                for bash/sh "TOMCAT_HOME=foo/jakarta-tomcat-3.2.1 ; export TOMCAT_HOME"<br>
  +                for tcsh "setenv TOMCAT_HOME foo/jakarta-tomcat-3.2.1"</li>
           </ol>
         </li>
         <li>Set the environment variable JAVA_HOME to point to the root
  @@ -170,9 +174,9 @@
       </blockquote>
       
       <h2>The Tomcat directory structure</h2>
  -    <p>Assuming you unzipped/untared the Tomcat binary distribution
  +    <p>Assuming you unzipped/untarred the Tomcat binary distribution
          you should have the following directory structure:</p>
  -    <table border width="75%" valign="MIDDLE">
  +    <table border="2" width="75%" valign="MIDDLE">
         <tr>
           <th bgcolor="#c0c0c0" WIDTH="25%"> Directory name</th>
           <th bgcolor="#c0c0c0" WIDTH="75%"> Description</th>
  @@ -220,7 +224,7 @@
   
       <p>Additionally you can, or Tomcat will, create the following
           directories:</p>
  -    <table border width="75%" VALIGN="MIDDLE">
  +    <table border="2" width="75%" VALIGN="MIDDLE">
         <tr>
           <td> work </td>
           <td> Automatically generated by Tomcat, this is where Tomcat
  @@ -254,7 +258,7 @@
   
       <p>What are these scripts? The following table presents the scripts that are
         most important for the common user:</p>
  -    <table border width="75%" valign="MIDDLE">
  +    <table border="2" width="75%" valign="MIDDLE">
         <tr>
           <th bgcolor="#c0c0c0" width="25%"> Script name </th>
           <th bgcolor="#c0c0c0" width="75%"> Description </th>
  @@ -284,7 +288,7 @@
         A closer look at tomcat.sh/tomcat.bat yields that it performs the
         following actions:</p>
   
  -    <table border =1 width="75%" valign="MIDDLE">
  +    <table border="1" width="75%" valign="MIDDLE">
         <tr>
           <th bgcolor="#c0c0c0" width="25%"> Operating System </th>
           <th bgcolor="#c0c0c0" width="75%"> Actions </th>
  @@ -322,8 +326,8 @@
             </ol>
             <p>For example, if server.xml is located in /etc/server_1.xml and
                the user wants to start Tomcat in the background, they should 
  -             provide the following command line: 
  -             <div>bin/tomcat.sh start -f /etc/server_1.xml</div></p>
  +             provide the following command line:</p>
  +             <div>bin/tomcat.sh start -f /etc/server_1.xml</div>
              </li>
          </ul>
           </td>
  @@ -361,8 +365,8 @@
           </ol>
           <p>For example, if server.xml is located in conf\server_1.xml and
              the user wants to start Tomcat in a new window, they should 
  -           provide the following command line: 
  -           <div>bin\tomcat.bat start -f conf\server_1.xml</div></p>
  +           provide the following command line:</p>
  +           <div>bin\tomcat.bat start -f conf\server_1.xml</div>
   
           </li>
           <li>Restores previously saved TOMCAT_HOME and CLASSPATH settings.</li></ul>
  @@ -372,7 +376,7 @@
   
       <p>As you can see, the Win32 version of tomcat.bat is not as robust as the Unix
         one. Especially, it does not guess the values of JAVA_HOME and only tries
  -      "." as a quess for TOMCAT_HOME.  It can build CLASSPATH dynamically, but
  +      "." as a guess for TOMCAT_HOME.  It can build CLASSPATH dynamically, but
         not in all cases.  It can not build CLASSPATH dynamically if TOMCAT_HOME
         contains spaces, or on Win9x, if TOMCAT_HOME contains non-8.3 directory
         names.</p>
  @@ -384,10 +388,11 @@
         <li> web.xml - Configures the various contexts in Tomcat. </li>
       </ol>
   
  -    This section will deal with how to use these files. We are not going to cover the internals
  -    of web.xml, these internals are covered in depth in the Servlet APIs spec. Instead we will
  -    cover the content of server.xml and discuss the usage of web.xml in the context of Tomcat.
  -  </p>
  +    <p>This section will deal with how to use these files. We are not
  +      going to cover the internals of web.xml, these internals are
  +      covered in depth in the Servlet APIs spec. Instead we will cover
  +      the content of server.xml and discuss the usage of web.xml in the
  +      context of Tomcat.</p>
   
       <h3><a name="server_xml"> server.xml </a></h3>
       <p> server.xml is Tomcat's main configuration file. It serves two goals:
  @@ -398,7 +403,7 @@
       server.xml.
       </ol>
       The important elements in server.xml are described in the following table:
  -    <table border width="75%" valign="MIDDLE">
  +    <table border="1" width="75%" valign="MIDDLE">
         <tr>
           <th bgcolor="#c0c0c0" width="20%"> Element </th>
           <th bgcolor="#c0c0c0" width="80%"> Description </th>
  @@ -436,7 +441,7 @@
           </td>
         </tr>
         <tr>
  -        <td> ContextInterceptor & RequestInterceptor </td>
  +        <td> ContextInterceptor &amp; RequestInterceptor </td>
           <td> These interceptors listen for certain events that happen in
            the ContextManager. For example, the ContextInterceptor listens for
            startup and shutdown events of Tomcat, and the RequestInterceptor
  @@ -488,16 +493,19 @@
       </td>
         </tr>
       </table><br>
  -    Additional information may be found within the server.xml file.
  -    </p>
  +
  +    <p>Additional information may be found within the server.xml file.</p>
  +
       <h3> Starting Tomcat From Another Directory </h3>
       
       <p>By default tomcat will use TOMCAT_HOME/conf/server.xml for configuration. The default 
  -       configuration will use TOMCAT_HOME as it's base for the contexts. </p>
  +       configuration will use TOMCAT_HOME as it's base for the contexts.</p>
  +
       <p>You can change this by using the "-f /path/to/server.xml" option, with a
          different server configuration file and setting the home property of
          the context manger. You need to set up the required files inside the
  -       home: </p>
  +       home:</p>
  +
           <ul>
             <li>A webapps/ directory (if you created one) - all war files will
                 be expanded and all subdirectories added as contexts.</li>
  @@ -556,11 +564,13 @@
       </ol>
   
       <h3> Web Server Operation </h3>
  -    <p> In a nutshell a web server is waiting for client HTTP requests.
  +
  +    <p>In a nutshell a web server is waiting for client HTTP requests.
           When these requests arrive the server does whatever is needed to 
           serve the requests by providing the necessary content. Adding a 
           servlet container may somewhat change this behavior. Now the web 
  -        server needs also to perform the following:
  +        server needs also to perform the following:</p>
  +
       <ul>
         <li> Load the servlet container adapter library and initialize it (prior
              to serving requests). </li>
  @@ -569,10 +579,9 @@
              take the request and handle it.</li>
       </ul>
   
  -    The adapter on the other hand needs to know what requests it is
  +    <p>The adapter on the other hand needs to know what requests it is
       going to serve, usually based on some pattern in the request URL, and to
  -    where to direct these requests.
  -  </p>
  +    where to direct these requests.</p>
   
       <p>
         Things are even more complex when the user wants to set a configuration
  @@ -582,11 +591,12 @@
       </p>
   
       <h3> What is the Needed Configuration </h3>
  -    <p> The most obvious configuration that one can think of is the identity of the servlet URLs
  +
  +    <p>The most obvious configuration that one can think of is the identity of the servlet URLs
         that are under the responsibility of the servlet container. This is clear; someone must
         know what requests to transmit to the servlet container...
         Yet there are additional configuration items that we should provide to
  -      the web-server/servlet-container combination:
  +      the web-server/servlet-container combination:</p>
       <ul>
         <li>We also need to provide configuration regarding the available Tomcat processes
       and on which TCP/IP host/port they are listening. </li>
  @@ -594,10 +604,10 @@
       will be able to load it on startup). </li>
         <li> We need to set adapter internal information such as where and how much to log, etc. </li>
       </ul>
  -    All this information must appear either in the web server configuration, or in a private
  +
  +    <p>All this information must appear either in the web server configuration, or in a private
       configuration files used by the adapter. The next section will demonstrate how configuration
  -    can be implemented on Apache.
  -  </p>
  +    can be implemented on Apache.</p>
   
   
       <h3> Making it on Apache </h3>
  @@ -630,7 +640,8 @@
   
       <p> The Apache-Tomcat configuration uses Apache core configuration directives
         as well as Jserv unique directives so it may confuse you at first, there are
  -      however two things simplifying it:
  +      however two things simplifying it:</p>
  +
       <ul>
         <li> In general you can distinguish between the two directive
              "families" by noting that all the Jserv unique directives start
  @@ -640,8 +651,9 @@
              generated tomcat-apache.conf, so you can look at a single file.
         </li>
       </ul>
  -    Lets look now at a sample tomcat.conf file.
  -    </p>
  +
  +    <p>Let's look now at a sample tomcat.conf file.</p>
  +
       <table border="1" 
              cellspacing="0" 
              cellpadding="0" 
  @@ -690,9 +702,10 @@
           </td> 
         </tr> 
       </table>
  -    </p>
  +
       <p>As you can see the configuration process was split into 4 steps
  -       that will now be explained:
  +       that will now be explained:</p>
  +
         <ol>
         <li> In this step we instruct Apache to load the jserv
              shared-object (or the NT world dll). This is a well known Apache
  @@ -727,26 +740,33 @@
              ApJServMount example is a rather simple one, in fact ApJServMount can
              also provide information regarding the communication protocol to be used
              and the location where the Tomcat process listens, for example:
  +
              <div><tt>ApJServMount /examples ajpv12://hostname:port/root</tt></div>
  +
              mounts the context /examples to a Tomcat process that runs on host
              "hostname" and listens on port number "port".
         </li>
       </ol>
  -    Now that you understand the different configuration instructions in the sample
  +
  +    <p>Now that you understand the different configuration instructions in the sample
       file, how can you add it to the Apache configuration? One "simple" method is to
  -    write it's content in the httpd.conf (the Apache configuration file), this however
  +    write its content in the httpd.conf (the Apache configuration file), this however
       can be very messy. Instead you should use the Apache include directive. At the end
  -    of the Apache configuration file (httpd.conf) add the following directive:
  +    of the Apache configuration file (httpd.conf) add the following directive:</p>
  +
       <div> <tt>include &lt;full path to the Tomcat configuration file&gt; </tt></div>
  -    for example:
  -    <div> <tt>include /tome/tomcat/conf/tomcat.conf </tt></div> This
  -    will add your Tomcat configuration to Apache, after that you should copy
  -    the jserv module to the Apache libexec (or modules in the Win32 case)
  -    directory and restart (stop+start) Apache. It should now be able to
  -    connect to Tomcat.
  -    </p>
  +
  +    <p>for example:</p>
  +
  +    <div> <tt>include /tome/tomcat/conf/tomcat.conf </tt></div>
  +    
  +    <p>This will add your Tomcat configuration to Apache, after that
  +    you should copy the jserv module to the Apache libexec (or modules
  +    in the Win32 case) directory and restart (stop+start) Apache. It
  +    should now be able to connect to Tomcat.</p>
   
       <h3> Obtaining the Jserv Module (mod_jserv) </h3>
  +
       <p> As previously stated, we need a web server adapter to sit in Apache and redirect
         requests to Tomcat. For Apache, this adapter is a slightly modified version of
         mod_jserv.
  @@ -797,9 +817,11 @@
       </ul>
         </li>
       </ol>
  -    That's it; you have built mod_jserv...
  -    </p>
  +
  +    <p>That's it; you have built mod_jserv...</p>
  +
       <h3> Making Apache Serve your Context's Static Files </h3>
  +
       <p> The previous Apache-Tomcat configuration file was somewhat
   	    inefficient, it instructed Apache to send any request for a resource
           that starts with the <tt>/examples</tt> prefix to be served by
  @@ -814,19 +836,20 @@
               <li>You may want to follow users requests for static resources
                   using interceptors. </li>
           </ol>
  -       In general however, this is not that case; and making Tomcat save
  +
  +       <p>In general however, this is not that case; and making Tomcat save
          static files is just a CPU waste. We should instead have Apache serve
  -       these static files and not Tomcat. Lets look now at a sample
  -       tomcat.conf file that does exactly that:
  -    </p>
  -    <p> Having Apache serve the static files requires the following:
  +       these static files and not Tomcat.</p>
  +
  +    <p>Having Apache serve the static files requires the following:
           <ol>
               <li>Instructing Apache to send all servlet requests to Tomcat. </li>
               <li>Instructing Apache to send all JSP requests to Tomcat. </li>
           </ol>
  -        and leaving Apache to handle the rest. Lets look now at a sample 
  -        tomcat.conf file that does exactly that:
  -    </p>
  +
  +        <p>and leaving Apache to handle the rest. Let's look now at a sample 
  +        tomcat.conf file that does exactly that:</p>
  +
       <table border="1" 
              cellspacing="0" 
              cellpadding="0" 
  @@ -884,7 +907,6 @@
           </td> 
         </tr> 
       </table>
  -    </p>
       
       <p>
         As you can see, the beginning of this configuration file is the same
  @@ -915,26 +937,28 @@
                context to Tomcat. </li>                                       
         </ol>
         
  -      It is easy to see that this configuration is much more complex and
  +      <p>It is easy to see that this configuration is much more complex and
         error prone then the first example, this however is the price that you 
  -      should (for now) pay for improved performance.
  -    </p>
  +      should (for now) pay for improved performance.</p>
   
  -    <h3> Configuring for Multiple Tomcat JVMs </h3>
  +    <h3>Configuring for Multiple Tomcat JVMs </h3>
  +
       <p>
           Sometimes it is useful to have different contexts handled by 
  -        different JVMs, for example: 
  +        different JVMs, for example:</p>
  +
           <ul>
               <li> When each context serves a different, specific task and runs
                    on a different machine. </li>
               <li> When we want to have multiple developers work on a private
                    Tomcat process but use the same web server. </li>
           </ul>
  -        Implementing such schemes where different contexts are served by
  +
  +        <p>Implementing such schemes where different contexts are served by
           different JVMs is very easy and the following configuration file
           demonstrates this:
       </p>
  -    <p>
  +
       <table border="1" 
           cellspacing="0" 
           cellpadding="0"     
  @@ -969,9 +993,9 @@
           </td> 
         </tr> 
       </table>
  -    </p>
  +
       <p>
  -    As you can see in the previous example, using several JVMs (even even 
  +    As you can see in the previous example, using several JVMs (even 
   	those that run on different machines) can be accomplished easily by 
   	using a full ajp URL mount. In this full URL we actually specify the 
   	host where the Tomcat process is located and it's port.
  @@ -1174,14 +1198,16 @@
       </p>
       <p>
           Then we should start the two tomcat processes using the -f command
  -        line option:
  -        <div> bin\starup -f conf\server_joe.xml</div>
  -        <div> bin\starup -f conf\server_bill.xml</div>
  -        and then access them from Apache based on the different URL path
  -        prefixes.
  -    </p>
  +        line option:</p>
   
  +        <div> bin\startup -f conf\server_joe.xml</div>
  +        <div> bin\startup -f conf\server_bill.xml</div>
  +
  +        <p>and then access them from Apache based on the different URL path
  +        prefixes.</p>
  +
       <h3> Configuring Virtual Hosting </h3>
  +
       <p>
           It is possible to support virtual hosts under Tomcat Ver3.2, in fact
           the virtual host configuration is very similar to configuring for
  @@ -1192,7 +1218,7 @@
   
       <p>
           With the current (Ver3.2) Tomcat, virtual hosting awareness is
  -        provided by the web server (Apache/Netscape�). The web server
  +        provided by the web server (Apache/Netscape). The web server
           virtual hosting support is used by the Tomcat adapter to
           redirect requests belonging to a certain virtual host to the JVM(s)
           containing the contexts of this virtual host. This means that if (for
  @@ -1205,7 +1231,6 @@
   		Apache-Tomcat configuration file:
       </p>
   
  -    <p>
       <table border="1"
           cellspacing="0"
           cellpadding="0"     
  @@ -1249,7 +1274,6 @@
           </td> 
         </tr> 
       </table>
  -    </p>
       
       <p>
           As can be seen, steps 1,2 and 3 define two Apache virtual hosts and 
  @@ -1283,10 +1307,11 @@
       </p>
   
       <h3> Modify and Customize the Batch Files </h3>
  -    <p>
  -        As stated in the previous sections, the startup scripts are here for 
  +
  +    <p>As stated in the previous sections, the startup scripts are here for 
   		your convenient.  Yet, sometimes the scripts that are needed for
  -        deployment should be modified:
  +        deployment should be modified:</p>
  +
           <ul>
               <li> To set resource limits such as maximum number of
                    descriptors. </li>
  @@ -1301,7 +1326,7 @@
               <li> Your pet reason. </li>
           </ul>
   
  -        Some of these changes can be done without explicit changes to
  +        <p>Some of these changes can be done without explicit changes to
           the basic scripts; for example, the tomcat script can use an 
   		environment variable named <tt>TOMCAT_OPTS</tt> to set extra command
           line parameters to the JVM (such as memory setting etc.).
  @@ -1310,14 +1335,17 @@
           as PATH, JAVA_HOME, TOMCAT_HOME and CLASSPATH from this file. On NT
           however (and also on UNIX when the modifications are for something
           such as the JVM command line) you are forced to rewrite some of the
  -        startup script... <div><b> Do not hesitate, just do it.</b> </div>
  -    </p>
  +        startup script...</p>
  +        
  +        <div><b> Do not hesitate, just do it.</b> </div>
  +
   
       <h3> Modify the Default JVM Settings </h3>
  -    <p>
  -        The default JVM settings in the tomcat script are very na�ve;
  +
  +    <p>The default JVM settings in the tomcat script are very na&iuml;ve;
           everything is left for defaults. There are a few things that you
  -        should consider to improve your Tomcat performance:
  +        should consider to improve your Tomcat performance:</p>
  +
           <ol>
               <li> Modify your JVM memory configuration. Normally the JVM
              allocates an initial size for the Java heap and that's it, if
  @@ -1346,15 +1374,13 @@
              and make a calculated decision.
              </li>
           </ol>
  -    </p>
   
       <h3> Modify your Connectors </h3>
  -    <p>
  -        The Connectors, as configured in Tomcat's default server.xml
  +
  +    <p>The Connectors, as configured in Tomcat's default server.xml
           contains two Connectors configured as in the next server.xml
  -        fragment:
  +        fragment:</p>
   
  -        <p>
           <table border="1"
               cellspacing="0"
               cellpadding="0"
  @@ -1384,7 +1410,6 @@
               </td>
             </tr>
           </table>
  -        </p>
   
           <ol>
               <li> Is a Connector that listens on port 8080 for incoming HTTP
  @@ -1395,16 +1420,16 @@
                    integration (out-of-process servlet integration).
           </ol>
   
  -        The AJPV12 Connector is required for Tomcat shutdown.  However, the
  -        HTTP Connector may be removed if stand-alone operation is not needed.
  -    </p>
  +        <p>The AJPV12 Connector is required for Tomcat shutdown.  However, the
  +        HTTP Connector may be removed if stand-alone operation is not needed.</p>
  +
       <h3> Use a Thread Pool in your Connectors </h3>
  -    <p>
  -        Tomcat is a multi-threaded servlet container this means that each
  +    <p>Tomcat is a multi-threaded servlet container this means that each
           request needs to be executed by some thread. Prior to Tomcat 3.2, the
           default was to create a new thread to serve each request that arrives.
           This behavior is problematic for loaded sites
  -        because:
  +        because:</p>
  +
           <ul>
               <li>Starting and stopping a thread  for every request puts a
                   needless burden on the operating system and the JVM. </li>
  @@ -1416,14 +1441,16 @@
                   Descriptors...) than it should and it can lead to low
                   performance and even crashes if resources are exhausted. </li>
           </ul>
  -        The solution for these problems is to use a <b>thread pool</b>, which
  +
  +        <p>The solution for these problems is to use a <b>thread pool</b>, which
           is the default for Tomcat 3.2.
           Servlet containers that are using a thread pool relieve themselves
           from directly managing their threads. Instead of allocating new
           threads; whenever they need a thread they ask for it from the pool,
           and when they are done, the thread is returned to the pool. The
           thread pool can now be used to implement sophisticated thread
  -        management techniques, such as:
  +        management techniques, such as:</p>
  +
           <ol>
               <li> Keeping threads "open" and reusing them over and over
                    again. This saves the trouble associated with creating and 
  @@ -1444,19 +1471,17 @@
                    </li> </ul>
               </li>
           </ol>
  -        You can refine the techniques described above in various ways, but
  +
  +        <p>You can refine the techniques described above in various ways, but
           these are only refinements. The main contribution of thread pools is
           thread-reuse and having a concurrency upper bound that limits
  -        resource usage.
  -    </p>
  +        resource usage.</p>
   
  -    <p>
  -        Using a thread pool in Tomcat is a simple move; all you need to do
  +        <p>Using a thread pool in Tomcat is a simple move; all you need to do
           is to use a <tt>PoolTcpConnector</tt> in your &lt;Connector&gt;
           configuration. For example the following server.xml fragment defines
  -        ajpv12, pooled Connector:
  +        ajpv12, pooled Connector:</p>
   
  -        <p>
           <table border="1"
               cellspacing="0"
               cellpadding="0"
  @@ -1480,10 +1505,10 @@
               </td>
             </tr>
           </table>
  -        </p>
   
  -        This fragment is very simple and the (default) pool behaviour
  -        instructed by it is:
  +        <p>This fragment is very simple and the (default) pool behaviour
  +        instructed by it is:</p>
  +
           <ul>
               <li> Upper bound for concurrency of 50 threads. </li>
               <li> When the pool has more then 25 threads standing idle it
  @@ -1492,12 +1517,13 @@
                    to keep 10 vacant threads (as long as the upper bound is
                    kept). </li>
           </ul>
  -        The default configuration is suitable for medium load sites with an
  +
  +        <p>The default configuration is suitable for medium load sites with an
           average of 10-40 concurrent requests. If your site differs you
           should modify this configuration (for example reduce the upper
           limit). Configuring the pool can be done through the &lt;Connector&gt;
  -        element in server.xml as demonstrated in the next fragment:
  -        <p>
  +        element in server.xml as demonstrated in the next fragment:</p>
  +
           <table border="1"
               cellspacing="0"
               cellpadding="0"
  @@ -1530,8 +1556,9 @@
               </td>
             </tr>
           </table>
  -        </p>
  -        As can be seen the pool has 3 configuration parameters:
  +
  +        <p>As can be seen the pool has 3 configuration parameters:</p>
  +
           <ul>
               <li> max_threads - defines the upper bound to the for the 
   			     concurrency, the pool will not create more then this number 
  @@ -1546,10 +1573,10 @@
                    be bigger then 0.</li>
           </ul>
   
  -        You should use the above parameters to adjust the pool behavior to
  -        your needs.
  -    </p>
  +        <p>You should use the above parameters to adjust the pool behavior to
  +        your needs.</p>
   
  +
       <h3> Disable Servlet Auto-Reloading </h3>
       <p>
           Servlet auto-reloading is really useful for development time.
  @@ -1564,18 +1591,21 @@
       </p>
   
       <h2>Authors</h2>
  -    <p>
  -      This document was created by:
  +    <p>This document was created by:</p>
  +
       <ul>
  -    <a href="mailto:shachor@il.ibm.com"> Gal Shachor</a>
  +    <li><a href="mailto:shachor@il.ibm.com"> Gal Shachor</a>
       </ul>
  -    With help from (alphabetical ordered):
  +
  +    <p>With help from (alphabetical ordered):</p>
  +
       <ul>
  -     Jonathan Bnayahu<br>
  -     Fiona Czuczman<br>
  -     Costin Manolache<br>
  +     <li>Jonathan Bnayahu
  +     <li>Fiona Czuczman
  +     <li>Costin Manolache
  +     <li>Chris Pepper
       </ul>
  -  </p>
  +  
   
       <table width="100%" border="0" cellpadding="10" cellspacing="0">
         <tr>