All,

New subscriber to this list and relative newbie to Tomcat. Have installed IIS5 
w/Tomcat 3.2.3 on W2K. Am having problems with redirection using isapsi. I get the 
"Error 501/505" when attempting http://myserver/examples/jsp/index. I have checked 
this archive list with the same error messages to no avail.

I *can* access http://myserver:8080/examples/jsp/index.html ok and all the examples 
work fine.

Completed:
-- created jakarta virtual directory with correct permissions per documentation
-- port on workers.properties = port on server.xml (8007)
--Tomcat started with no errors
-- IIS started w/no errors
-- triple checked the path where isapi_redirect.dll is correct in IIS Manager.
-- Checked the Tomcat IISHowTo document from jakarta.apache.org. 

This is from my iis_redirect.log.

jk_uri_worker_map.c (185)]: In jk_uri_worker_map_t::uri_worker_map_free, NULL 
parameters
[jk_uri_worker_map.c (431)]: In jk_uri_worker_map_t::map_uri_to_worker, wrong 
parameters
[jk_uri_worker_map.c (431)]: In jk_uri_worker_map_t::map_uri_to_worker, wrong 
parameters

Checked the uriworkers.properties file:

#
# Simple worker configuration file
#

# Mount the servlet context to the ajp12 worker
/servlet/*=ajp12

# Mount the examples context to the ajp12 worker
/examples/*=ajp12

# Advanced mount of the examples context
# /examples/*.jsp=ajp12
# /examples/servlet/*=ajp12



Here is my workers.properties file:

#
# $Header: /home/cvs/jakarta-tomcat/src/etc/Attic/workers.properties,v 1.3.2.2 
2000/10/16 01:59:22 larryi Exp $
# $Revision: 1.3.2.2 $
# $Date: 2000/10/16 01:59:22 $
#
#
# workers.properties -
#
# This file provides jk derived plugins with with the needed information to
# connect to the different tomcat workers.
#
# As a general note, the characters $( and ) are used internally to define
# macros. Do not use them in your own configuration!!!
#
# Whenever you see a set of lines such as:
# x=value
# y=$(x)\something
#
# the final value for y will be value\something
#
# Normaly all you will need to modify is the first properties, i.e.
# workers.tomcat_home, workers.java_home and ps. Most of the configuration
# is derived from these.
#
# When you are done updating workers.tomcat_home, workers.java_home and ps
# you should have 3 workers configured:
#
# - An ajp12 worker that connects to localhost:8007
# - An ajp13 worker that connects to localhost:8009
# - A jni inprocess worker.
# - A load balancer worker
#
# However by default the plugins will only use the ajp12 worker. To have
# the plugins use other workers you should modify the worker.list property.
#
#

#
# workers.tomcat_home should point to the location where you
# installed tomcat. This is where you have your conf, webapps and lib
# directories.
#
workers.tomcat_home=d:\tomcat

#
# workers.java_home should point to your Java installation. Normally
# you should have a bin and lib directories beneath it.
#
workers.java_home=d:\jdk

#
# You should configure your environment slash... ps=\ on NT and / on UNIX
# and maybe something different elsewhere.
#
ps=\
# ps=/

#
#------ ADVANCED MODE ------------------------------------------------
#---------------------------------------------------------------------
#

#
#------ DEFAULT worket list ------------------------------------------
#---------------------------------------------------------------------
#
#
# The workers that your plugins should create and work with
#
worker.list=ajp12, ajp13

#
#------ DEFAULT ajp12 WORKER DEFINITION ------------------------------
#---------------------------------------------------------------------
#

#
# Defining a worker named ajp12 and of type ajp12
# Note that the name and the type do not have to match.
#
worker.ajp12.port=8007
worker.ajp12.host=localhost
worker.ajp12.type=ajp12
#
# Specifies the load balance factor when used with
# a load balancing worker.
# Note:
#  ----> lbfactor must be > 0
#  ----> Low lbfactor means less work done by the worker.
worker.ajp12.lbfactor=1

#
#------ DEFAULT ajp13 WORKER DEFINITION ------------------------------
#---------------------------------------------------------------------
#

#
# Defining a worker named ajp13 and of type ajp13
# Note that the name and the type do not have to match.
#
worker.ajp13.port=8009
worker.ajp13.host=localhost
worker.ajp13.type=ajp13
#
# Specifies the load balance factor when used with
# a load balancing worker.
# Note:
#  ----> lbfactor must be > 0
#  ----> Low lbfactor means less work done by the worker.
worker.ajp13.lbfactor=1

#
# Specify the size of the open connection cache.
#worker.ajp13.cachesize

#
#------ DEFAULT LOAD BALANCER WORKER DEFINITION ----------------------
#---------------------------------------------------------------------
#

#
# The loadbalancer (type lb) workers perform wighted round-robin
# load balancing with sticky sessions.
# Note:
#  ----> If a worker dies, the load balancer will check its state
#        once in a while. Until then all work is redirected to peer
#        workers.
worker.loadbalancer.type=lb
worker.loadbalancer.balanced_workers=ajp12, ajp13


#
#------ DEFAULT JNI WORKER DEFINITION---------------------------------
#---------------------------------------------------------------------
#

#
# Defining a worker named inprocess and of type jni
# Note that the name and the type do not have to match.
#
worker.inprocess.type=jni

#
#------ CLASSPATH DEFINITION -----------------------------------------
#---------------------------------------------------------------------
#

#
# Additional class path components.
#
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)classes

#
# The XML parser provided with Tomcat
#
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)jaxp.jar
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)parser.jar

#
# Tomcat's implementation
#
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)jasper.jar
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)servlet.jar
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)webserver.jar

#
# Javac as available from Java2SE
#
worker.inprocess.class_path=$(workers.java_home)$(ps)lib$(ps)tools.jar

#
# Setting the command line for tomcat
# Note: The cmd_line string may not contain spaces.
#
worker.inprocess.cmd_line=-config
worker.inprocess.cmd_line=$(workers.tomcat_home)/conf/jni_server.xml
worker.inprocess.cmd_line=-home
worker.inprocess.cmd_line=$(workers.tomcat_home)

#
# The JVM that we are about to use
#
# This is for Java2
#
worker.inprocess.jvm_lib=$(workers.java_home)$(ps)jre$(ps)bin$(ps)classic$(ps)jvm.dll

#
# And this is for jdk1.1.X
#
#worker.inprocess.jvm_lib=$(workers.java_home)$(ps)bin$(ps)javai.dll
#

#
# Setting the place for the stdout and stderr of tomcat
#
worker.inprocess.stdout=$(workers.tomcat_home)$(ps)inprocess.stdout
worker.inprocess.stderr=$(workers.tomcat_home)$(ps)inprocess.stderr

#
# Setting the tomcat.home Java property
#
worker.inprocess.sysprops=tomcat.home=$(workers.tomcat_home)

#
# Java system properties
#
# worker.inprocess.sysprops=java.compiler=NONE
# worker.inprocess.sysprops=myprop=mypropvalue

#
# Additional path components.
#
# worker.inprocess.ld_path=d:$(ps)SQLLIB$(ps)bin
#



HERE IS MY web.xml FILE:


<?xml version="1.0" encoding="ISO-8859-1"?>

<Server>
    <!-- Debug low-level events in XmlMapper startup 
    <xmlmapper:debug level="0" />
    -->
    
    <!-- 

    Logging:

         Logging in Tomcat is quite flexible; we can either have a log
         file per module (example: ContextManager) or we can have one
         for Servlets and one for Jasper, or we can just have one
         tomcat.log for both Servlet and Jasper.  Right now there are
         three standard log streams, "tc_log", "servlet_log", and
         "JASPER_LOG".  

         Path: 

         The file to which to output this log, relative to
         TOMCAT_HOME.  If you omit a "path" value, then stderr or
         stdout will be used.

         Verbosity: 

         Threshold for which types of messages are displayed in the
         log.  Levels are inclusive; that is, "WARNING" level displays
         any log message marked as warning, error, or fatal.  Default
         level is WARNING.

         verbosityLevel values can be: 
            FATAL
            ERROR
            WARNING 
            INFORMATION
            DEBUG

         Timestamps:

         By default, logs print a timestamp in the form "yyyy-MM-dd
         hh:mm:ss" in front of each message.  To disable timestamps
         completely, set 'timestamp="no"'. To use the raw
         msec-since-epoch, which is more efficient, set
         'timestampFormat="msec"'.  If you want a custom format, you
         can use 'timestampFormat="hh:mm:ss"' following the syntax of
         java.text.SimpleDateFormat (see Javadoc API).  For a
         production environment, we recommend turning timestamps off,
         or setting the format to "msec".

         Custom Output:

         "Custom" means "normal looking".  "Non-custom" means
         "surrounded with funny xml tags".  In preparation for
         possibly disposing of "custom" altogether, now the default is
         'custom="yes"' (i.e. no tags)

         Per-component Debugging:

         Some components accept a "debug" attribute.  This further
         enhances log output.  If you set the "debug" level for a
         component, it may output extra debugging information.
    -->

    <!-- if you don't want messages on screen, add the attribute
            path="logs/tomcat.log" 
         to the Logger element below
    -->
    <Logger name="tc_log" 
            verbosityLevel = "INFORMATION" 
    />

    <Logger name="servlet_log" 
            path="logs/servlet.log"
    />

    <Logger name="JASPER_LOG" 
            path="logs/jasper.log"
            verbosityLevel = "INFORMATION" />

    <!-- You can add a "home" attribute to represent the "base" for 
         all relative paths. If none is set, the TOMCAT_HOME property
         will be used, and if not set "." will be used.
         webapps/, work/ and logs/ will be relative to this ( unless 
         set explicitely to absolute paths ).

         You can also specify a "randomClass" attribute, which determines 
         a subclass of java.util.Random will be used for generating session IDs.
         By default this is "java.security.SecureRandom". 
         Specifying "java.util.Random" will speed up Tomcat startup, 
         but it will cause sessions to be less secure.

         You can specify the "showDebugInfo" attribute to control whether
         debugging information is displayed in Tomcat's default responses.
         This debugging information includes:
             1. Stack traces for exceptions
             2. Request URI's that cause status codes >= 400
         The default is "true", so you must specify "false" to prevent
         the debug information from appearing.  Since the debugging
         information reveals internal details about what Tomcat is serving,
         set showDebugInfo="false" if you wish increased security.
      -->
    <ContextManager debug="0" workDir="work" showDebugInfo="true" >

      <!-- ==================== Interceptors ==================== -->

        <!-- 
         ContextInterceptor className="org.apache.tomcat.context.LogEvents" 
         -->
        
        <ContextInterceptor className="org.apache.tomcat.context.AutoSetup" />

        <ContextInterceptor 
            className="org.apache.tomcat.context.WebXmlReader" />

        <!-- Uncomment out if you have JDK1.2 and want to use policy 
        <ContextInterceptor 
            className="org.apache.tomcat.context.PolicyInterceptor" />
        -->

        <ContextInterceptor 
            className="org.apache.tomcat.context.LoaderInterceptor" />
        <ContextInterceptor 
            className="org.apache.tomcat.context.DefaultCMSetter" />
        <ContextInterceptor 
            className="org.apache.tomcat.context.WorkDirInterceptor" />

        <!--  Uncomment if you are using JDK1.2 or higher.  
              Insures proper thread context class loader is in effect for servlet 
execution
        <ContextInterceptor 
            className="org.apache.tomcat.request.Jdk12Interceptor" />
        -->

        <!-- Request processing -->
        <!-- Session interceptor will extract the session id from cookies and 
             deal with URL rewriting ( by fixing the URL ).  If you wish to
             suppress the use of cookies for session identifiers, change the
             "noCookies" attribute to "true"
          -->
        <RequestInterceptor 
            className="org.apache.tomcat.request.SessionInterceptor"
            noCookies="false" />

        <!-- Find the container ( context and prefix/extension map ) 
             for a request.
          -->
        <RequestInterceptor 
            className="org.apache.tomcat.request.SimpleMapper1" 
            debug="0" />

        <!-- Non-standard invoker, for backward compat. ( /servlet/* )
             You can modify the prefix that is matched by adjusting the
             "prefix" parameter below.  Be sure your modified pattern
             starts and ends with a slash.

             NOTE:  This prefix applies to *all* web applications that
             are running in this instance of Tomcat.
          -->
        <RequestInterceptor 
            className="org.apache.tomcat.request.InvokerInterceptor" 
            debug="0" prefix="/servlet/" />

        <!-- "default" handler - static files and dirs.  Set the
             "suppress" property to "true" to suppress directory listings
             when no welcome file is present.

             NOTE:  This setting applies to *all* web applications that
             are running in this instance of Tomcat.
          -->
        <RequestInterceptor 
            className="org.apache.tomcat.request.StaticInterceptor" 
            debug="0" suppress="false" />

        <!-- Plug a session manager. You can plug in more advanced session
             modules.
          -->
        <RequestInterceptor 
            className="org.apache.tomcat.session.StandardSessionInterceptor" />

        <!-- Check if the request requires an authenticated role.
          -->
        <RequestInterceptor 
            className="org.apache.tomcat.request.AccessInterceptor" 
            debug="0" />

        <!-- Check permissions using the simple xml file. You can 
             plug more advanced authentication modules.
          -->
        <RequestInterceptor 
            className="org.apache.tomcat.request.SimpleRealm" 
            debug="0" />

       <!-- UnComment the following and comment out the
            above to get a JDBC realm.
            Other options for driverName: 
              driverName="oracle.jdbc.driver.OracleDriver"
              connectionURL="jdbc:oracle:thin:@ntserver:1521:ORCL"
              connectionName="scott"
              connectionPassword="tiger"

              driverName="org.gjt.mm.mysql.Driver"
              connectionURL="jdbc:mysql://localhost/authority"
              connectionName="test"
              connectionPassword="test"

            "connectionName" and "connectionPassword" are optional.
        -->
        <!--
        <RequestInterceptor 
            className="org.apache.tomcat.request.JDBCRealm" 
            debug="99" 
            driverName="sun.jdbc.odbc.JdbcOdbcDriver" 
            connectionURL="jdbc:odbc:TOMCAT" 
            userTable="users" 
            userNameCol="user_name" 
            userCredCol="user_pass" 
            userRoleTable="user_roles" 
            roleNameCol="role_name" />
        -->

        <!-- Loaded last since JSP's that load-on-startup use request handling -->
        <ContextInterceptor 
            className="org.apache.tomcat.context.LoadOnStartupInterceptor" />

      <!-- ==================== Connectors ==================== -->

        <!-- Normal HTTP -->
        <Connector className="org.apache.tomcat.service.PoolTcpConnector">
            <Parameter name="handler" 
                value="org.apache.tomcat.service.http.HttpConnectionHandler"/>
            <Parameter name="port" 
                value="8080"/>
        </Connector>

        <!--
            Uncomment this for SSL support. 
            You _need_ to set up a server certificate if you want this
            to work, and you need JSSE.
            1. Add JSSE jars to CLASSPATH 
            2. Edit java.home/jre/lib/security/java.security
               Add:
               security.provider.2=com.sun.net.ssl.internal.ssl.Provider
            3. Do: keytool -genkey -alias tomcat -keyalg RSA
               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 )
         -->
        <!--
        <Connector className="org.apache.tomcat.service.PoolTcpConnector">
            <Parameter name="handler" 
                value="org.apache.tomcat.service.http.HttpConnectionHandler"/>
            <Parameter name="port" 
                value="8443"/>
            <Parameter name="socketFactory" 
                value="org.apache.tomcat.net.SSLSocketFactory" />
        </Connector>
        -->

        <!-- Apache AJP12 support. This is also used to shut down tomcat.
          -->
        <Connector className="org.apache.tomcat.service.PoolTcpConnector">
            <Parameter name="handler" 
       value="org.apache.tomcat.service.connector.Ajp12ConnectionHandler"/>
            <Parameter name="port" value="8007"/>
        </Connector>

        
- <!--  Define an SSL HTTP/1.1 Connector on port 443 --> 


        <!-- ==================== Special webapps ==================== -->
        <!-- You don't need this if you place your app in webapps/
             and use defaults. 
             For security you'll also need to edit tomcat.policy

             Defaults are: debug=0, reloadable=true, trusted=false
             (trusted allows you to access tomcat internal objects 
             with FacadeManager ), crossContext=true (allows you to
             access other contexts via ServletContext.getContext())
 
             If security manager is enabled, you'll have read perms.
             in the webapps dir and read/write in the workdir.
         -->

        <Context path="/examples" 
                 docBase="webapps/examples" 
                 crossContext="false"
                 debug="0" 
                 reloadable="true" > 
        </Context>

        <!-- Admin context will use tomcat.core to add/remove/get info about
             the webapplications and tomcat internals. 
             By default it is not trusted - i.e. it is not allowed access to 
             tomcat internals, only informations that are available to all 
             servlets are visible.

             If you change this to true, make sure you set a password.
          -->
        <Context path="/admin" 
                 docBase="webapps/admin" 
                 crossContext="true"
                 debug="0" 
                 reloadable="true" 
                 trusted="false" > 
        </Context>

        <!-- Virtual host example - 
             In "127.0.0.1" virtual host we'll reverse "/" and 
             "/examples"
             (XXX need a better example )
             (use  "http://127.0.0.1/examples"; )
        <Host name="127.0.0.1" >
           <Context path="" 
                    docBase="webapps/examples" />
           <Context path="/examples" 
                    docBase="webapps/ROOT" />
        </Host>
         -->

    </ContextManager>
</Server>





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to