> -----Original Message-----
> From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, January 03, 2001 12:29 PM
> To: [EMAIL PROTECTED]
> Subject: Re: multiple instances of Tomcat
>
>
> Amy Roh wrote:
>
> > Does tomcat allow multiple instances running on the same machine?
>
> You can do this if you run Tomcat on different port numbers.
>
> >  What happens
> > if you have different JSP files with same name on different
> ports?  Does it
> > create one java file or two?  Will one overwrite the other one?
> >
>
> There's two different scenarios:
>
> * Do you have separate TOMCAT_HOME directory hierarchies?
>   If so, everything is independent of each other, and no overwrites
>   will occur
>
> * Are you sharing TOMCAT_HOME directories?  You are most
>   likely going to have overwrite problems, because the work directories
>   will be shared.

Do you truly need completely different TOMCAT_HOME directory trees?
I assumed that using different log and work hierarchies would be sufficient.
I have been experimenting with the following:

In TOMCAT_HOME, I have separate startup.sh files, which identify specific
server.xml files, as follows:
$BASEDIR/tomcat.sh start -security -config ../conf/server_tst.xml "$@"

The server.xml file (or, in this case, server_tst.xml file), then specifies
a specific log and work directory structure, as follows:

    <Logger name="tc_log"
            path="logs/tst/tomcat.log"
            verbosityLevel = "DEBUG"

    />
..... and later .....
<ContextManager debug="0" workDir="work/tst" showDebugInfo="true" >

server_tst.xml also has the the autosetup line commented out, and the
specific context
I want to use is identified:
        <!--
        <ContextInterceptor className="org.apache.tomcat.context.AutoSetup"
/>
        -->
..... and later .....
        <Context path="/tst"

                 docBase="webapps/tst"

                 crossContext="false"

                 debug="0"

                 reloadable="true">

        </Context>


It seems to me that this, along with the port changes, should work, but I'm
getting
errors, like this:
2001-01-03 08:50:09 - ContextManager: Error reading request, ignored -
java.lang.NullPointerExceptio
n
        at
org.apache.tomcat.core.ContextManager.handleError(ContextManager.java:1099)
        at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:80
0)
        at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
        at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC
onnectionHand
ler.java:210)
        at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
        at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)
        at java.lang.Thread.run(Thread.java:484)


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

Reply via email to