Re: Problem deploying existing webapp in new Tomcat container

2007-05-17 Thread Rob Tanner
Since it's your favorite subject...   :-)

Following the directions in the context.html doc (the fisrt URL below),
and not changing the default values for engine and host, the first thing
I did was to add the path ${CATALINA_HOME}/conf/Catalina/localhost.  I
created one xml file named: mailtools#aliases.xml since the context path
is multi-level (the path is /mailtools/aliases -- I presume that's
what was meant by multi-level in the doc) for the first webapp and
accntManager.xml for the seconf app.

The first app (mailtools#aliases.xml) still continues to fail as below:

SEVERE: Allocate exception for servlet GroupAliasManager
javax.servlet.ServletException: Error instantiating servlet class
GroupAliasManager
at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1127)
at
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:806)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:129)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581)
at
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:595)

The second app, that was working properly when I configured it's context
in server.xml now fails to load:

java.lang.IllegalArgumentException: Document base
/var/apache/apache-tomcat-6.0.13/webapps/accntManager does not exist or
is not a readable directory. 

The specified docBase is AccountManager not accntManager.  The latter is
the context path.  Although, when I rename the actual directory
accntManager it works.  It clearly misreading something which tells me
that I'm clearly misunderstanding something.

Here are the two files:

Context crossContext=true debug=0
   docBase=AccountManager path=/accntManager reloadable=true
   Logger className=org.apache.catalina.logger.FileLogger
 prefix=localhost_accntmanager_log. suffix=.txt
  timestamp=true/
/Context
::
mailtools#aliases.xml
::
Context crossContext=true debug=0
   docBase=GroupAliases path=/mailtools/aliases reloadable=true
   Logger className=org.apache.catalina.logger.FileLogger
 prefix=localhost_aliases_log. suffix=.txt
  timestamp=true/
/Context

Thanks,
Rob


Caldarale, Charles R said the following on 05/16/2007 03:19 PM:
 From: Rob Tanner [mailto:[EMAIL PROTECTED] 
 Subject: Re: Problem deploying existing webapp in new Tomcat container
 
  
   
 As far as server.xml, how else does one specify the specifics, such as
 
 the path variable? 
  
 (Here we go again... my favorite subject :-)
  
 First, read the doc:
 http://tomcat.apache.org/tomcat-6.0-doc/config/context.html
  
 Note the following extracts from the Introduction and the description of
 the path attribute:
  
 For Tomcat 6, unlike Tomcat 4.x, it is NOT recommended to place
 Context elements directly in the server.xml file. This is because it
 makes modifing the Context configuration more invasive since the main
 conf/server.xml file cannot be reloaded without restarting Tomcat.
  
 The value of this field must not be set except when statically defining
 a Context in server.xml, as it will be inferred from the filenames used
 for either the .xml context file or the docBase.
  
 Nor should you be specifying a docBase. Put the Context elements where
 they belong - in META-INF/context.xml of each webapp - and remove the
 path and docBase attributes.
  
 Also, reading this part of the doc:
 http://tomcat.apache.org/tomcat-6.0-doc/logging.html
  
 would show you that the Logger element is no longer used.
  
  - Chuck
  

 THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
 MATERIAL and is thus for use only by the intended recipient. If you
 received this in error, please contact the sender and delete the e-mail
 and its attachments from all computers.

  


   

-- 
Rob Tanner
UNIX Services Manager
Linfield College, McMinnville OR


smime.p7s
Description: S/MIME Cryptographic Signature


Re: Problem deploying existing webapp in new Tomcat container

2007-05-17 Thread Rob Tanner
I also found this log, and I assume it's related to the problem:

WARNING: A docBase /var/apache/apache-tomcat-6.0.13/webapps/GroupAliases
inside the host appBase has been specified, and will be ignored


You can see in the dump of mailtools#aliases.xml that indeed I do
specify a docBase.  In Tomcat 4 that was correct but now that's wrong?? 
Makes no sense.

-- Rob


Rob Tanner said the following on 05/17/2007 10:09 AM:
 Since it's your favorite subject...   :-)

 Following the directions in the context.html doc (the fisrt URL
 below), and not changing the default values for engine and host, the
 first thing I did was to add the path
 ${CATALINA_HOME}/conf/Catalina/localhost.  I created one xml file
 named: mailtools#aliases.xml since the context path is multi-level
 (the path is /mailtools/aliases -- I presume that's what was meant
 by multi-level in the doc) for the first webapp and accntManager.xml
 for the seconf app.

 The first app (mailtools#aliases.xml) still continues to fail as below:

 SEVERE: Allocate exception for servlet GroupAliasManager
 javax.servlet.ServletException: Error instantiating servlet class
 GroupAliasManager
 at
 org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1127)
 at
 org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:806)
 at
 org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:129)
 at
 org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
 at
 org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
 at
 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
 at
 org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
 at
 org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
 at
 org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261)
 at
 org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
 at
 org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581)
 at
 org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
 at java.lang.Thread.run(Thread.java:595)

 The second app, that was working properly when I configured it's
 context in server.xml now fails to load:

 java.lang.IllegalArgumentException: Document base
 /var/apache/apache-tomcat-6.0.13/webapps/accntManager does not exist
 or is not a readable directory. 

 The specified docBase is AccountManager not accntManager.  The latter
 is the context path.  Although, when I rename the actual directory
 accntManager it works.  It clearly misreading something which tells
 me that I'm clearly misunderstanding something.

 Here are the two files:

 Context crossContext=true debug=0
docBase=AccountManager path=/accntManager reloadable=true
Logger className=org.apache.catalina.logger.FileLogger
  prefix=localhost_accntmanager_log. suffix=.txt
   timestamp=true/
 /Context
 ::
 mailtools#aliases.xml
 ::
 Context crossContext=true debug=0
docBase=GroupAliases path=/mailtools/aliases reloadable=true
Logger className=org.apache.catalina.logger.FileLogger
  prefix=localhost_aliases_log. suffix=.txt
   timestamp=true/
 /Context

 Thanks,
 Rob


 Caldarale, Charles R said the following on 05/16/2007 03:19 PM:
 From: Rob Tanner [mailto:[EMAIL PROTECTED] 
 Subject: Re: Problem deploying existing webapp in new Tomcat container
 
  
   
 As far as server.xml, how else does one specify the specifics, such as
 
 the path variable? 
  
 (Here we go again... my favorite subject :-)
  
 First, read the doc:
 http://tomcat.apache.org/tomcat-6.0-doc/config/context.html
  
 Note the following extracts from the Introduction and the description of
 the path attribute:
  
 For Tomcat 6, unlike Tomcat 4.x, it is NOT recommended to place
 Context elements directly in the server.xml file. This is because it
 makes modifing the Context configuration more invasive since the main
 conf/server.xml file cannot be reloaded without restarting Tomcat.
  
 The value of this field must not be set except when statically defining
 a Context in server.xml, as it will be inferred from the filenames used
 for either the .xml context file or the docBase.
  
 Nor should you be specifying a docBase. Put the Context elements where
 they belong - in META-INF/context.xml of each webapp - and remove the
 path and docBase attributes.
  
 Also, reading this part of the doc:
 http://tomcat.apache.org/tomcat-6.0-doc/logging.html
  
 would show you that the Logger element is no longer used.
  
  - Chuck
  

 THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
 MATERIAL and is thus for use only by the intended recipient. If you

RE: Problem deploying existing webapp in new Tomcat container

2007-05-17 Thread Caldarale, Charles R
 From: Rob Tanner [mailto:[EMAIL PROTECTED] 
 Subject: Re: Problem deploying existing webapp in new Tomcat container
 
 the first thing I did was to add the path 
 ${CATALINA_HOME}/conf/Catalina/localhost.

What does add the path mean?  That directory should have already
existed.

 I created one xml file named: mailtools#aliases.xml since the 
 context path is multi-level (the path is /mailtools/aliases
 -- I presume that's what was meant by multi-level in the doc)
 for the first webapp and accntManager.xml for the seconf app.

You didn't say so explicitly, but I presume you placed these .xml files
in conf/Catalina/localhost.

 Context crossContext=true debug=0
 docBase=GroupAliases path=/mailtools/aliases
reloadable=true
   Logger className=org.apache.catalina.logger.FileLogger
   prefix=localhost_aliases_log. suffix=.txt timestamp=true/
 /Context
 Context crossContext=true debug=0
 docBase=AccountManager path=/accntManager reloadable=true
   Logger className=org.apache.catalina.logger.FileLogger
   prefix=localhost_accntmanager_log. suffix=.txt
   timestamp=true/
 /Context

The path attribute is not allowed - get rid of it.  A docBase attribute
relative to appBase is also not allowed, so get rid of that.  As at
least two people have told you, the Logger element is no longer
allowed, so that goes as well.  (You can configure individual webapp
logging by following the doc here:
http://tomcat.apache.org/tomcat-6.0-doc/logging.html.)

So now we're left with just:

Context crossContext=true debug=0 reloadable=true
/Context

for each webapp.  However, that's not going to work for the multi-level
path one.  Any app using a multi-level path cannot be placed under the
Host's appBase - it must be located elsewhere, or double deployments
can occur.  Let's assume you'll put it in ${CATALINA_HOME}/otherapps;
your Context for mailtools#aliases.xml now becomes:

Context crossContext=true debug=0 reloadable=true
 docBase=${catalina.home}/otherapps/GroupAliases
/Context

(The above assumes you have an unpacked webapp, not a .war file.)

For the second webapp, simply rename the directory from AccountManager
to accntManager; if you're going to deploy under the appBase directory,
the name of the sub-directory (or .war file) IS the URI path to the
webapp - no exceptions.  If you want something different, the webapp
must be located somewhere other than under appBase.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problem deploying existing webapp in new Tomcat container

2007-05-17 Thread Pid

Rob Tanner wrote:

I also found this log, and I assume it's related to the problem:

WARNING: A docBase /var/apache/apache-tomcat-6.0.13/webapps/GroupAliases 
inside the host appBase has been specified, and will be ignored



You can see in the dump of mailtools#aliases.xml that indeed I do 
specify a docBase.  In Tomcat 4 that was correct but now that's wrong??  
Makes no sense.


It does make sense - there's been 3 major releases (5.0, 5.5 and 6.0) 
since then, each introduced incremental changes.  Chuck explained that 
you should remove the 'path' and 'docBase' attributes.


The error message is a warning - so it's probably not affecting you.

Have you implemented the recommended solution?


p





-- Rob


Rob Tanner said the following on 05/17/2007 10:09 AM:

Since it's your favorite subject...   :-)

Following the directions in the context.html doc (the fisrt URL 
below), and not changing the default values for engine and host, the 
first thing I did was to add the path 
${CATALINA_HOME}/conf/Catalina/localhost.  I created one xml file 
named: mailtools#aliases.xml since the context path is multi-level 
(the path is /mailtools/aliases -- I presume that's what was meant 
by multi-level in the doc) for the first webapp and accntManager.xml 
for the seconf app.


The first app (mailtools#aliases.xml) still continues to fail as below:

SEVERE: Allocate exception for servlet GroupAliasManager
javax.servlet.ServletException: Error instantiating servlet class 
GroupAliasManager
at 
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1127)
at 
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:806)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:129)
at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at 
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261)
at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581)
at 
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

at java.lang.Thread.run(Thread.java:595)

The second app, that was working properly when I configured it's 
context in server.xml now fails to load:


java.lang.IllegalArgumentException: Document base 
/var/apache/apache-tomcat-6.0.13/webapps/accntManager does not exist 
or is not a readable directory. 

The specified docBase is AccountManager not accntManager.  The latter 
is the context path.  Although, when I rename the actual directory 
accntManager it works.  It clearly misreading something which tells 
me that I'm clearly misunderstanding something.


Here are the two files:

Context crossContext=true debug=0
   docBase=AccountManager path=/accntManager reloadable=true
   Logger className=org.apache.catalina.logger.FileLogger
 prefix=localhost_accntmanager_log. suffix=.txt
  timestamp=true/
/Context
::
mailtools#aliases.xml
::
Context crossContext=true debug=0
   docBase=GroupAliases path=/mailtools/aliases reloadable=true
   Logger className=org.apache.catalina.logger.FileLogger
 prefix=localhost_aliases_log. suffix=.txt
  timestamp=true/
/Context

Thanks,
Rob


Caldarale, Charles R said the following on 05/16/2007 03:19 PM:
From: Rob Tanner [mailto:[EMAIL PROTECTED] 
Subject: Re: Problem deploying existing webapp in new Tomcat container

 
  

As far as server.xml, how else does one specify the specifics, such as

the path variable? 
 
(Here we go again... my favorite subject :-)
 
First, read the doc:

http://tomcat.apache.org/tomcat-6.0-doc/config/context.html
 
Note the following extracts from the Introduction and the description of

the path attribute:
 
For Tomcat 6, unlike Tomcat 4.x, it is NOT recommended to place

Context elements directly in the server.xml file. This is because it
makes modifing the Context configuration more invasive since the main
conf/server.xml file cannot be reloaded without restarting Tomcat.
 
The value of this field must not be set except when statically defining

a Context in server.xml, as it will be inferred from the filenames used
for either the .xml context file or the docBase.
 
Nor should you be specifying a docBase. Put the Context elements where

they belong - in META-INF/context.xml of each webapp - and remove the
path and docBase attributes.
 
Also, reading this part

Problem deploying existing webapp in new Tomcat container

2007-05-16 Thread Rob Tanner
Hi,

I am in the process of upgrading my Tomcat environment.  On a new server
I installed Sun Java jdk1.6.0 and apache-tomcat-6.0.13. I copied over
the server.xml config for the first web aplication as well as the JAR
file and everything worked fine.  When I did the same for the second
application, this is the entire error message.  Problem is that it
doesn't give me the slightest clue as to the cause of the problem, or
why the one app works and this one doesn't.


May 16, 2007 1:58:45 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Allocate exception for servlet GroupAliasManager
javax.servlet.ServletException: Error instantiating servlet class
GroupAliasManager
at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1127)
at
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:806)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:129)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581)
at
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)


Any ideas?

Thanks,
Rob




-- 
Rob Tanner
UNIX Services Manager
Linfield College, McMinnville OR



smime.p7s
Description: S/MIME Cryptographic Signature


RE: Problem deploying existing webapp in new Tomcat container

2007-05-16 Thread Caldarale, Charles R
 From: Rob Tanner [mailto:[EMAIL PROTECTED] 
 Subject: Problem deploying existing webapp in new Tomcat container
 
 I installed Sun Java jdk1.6.0 and apache-tomcat-6.0.13. I copied over
 the server.xml config for the first web aplication as well as the JAR
 file and everything worked fine.

That sounds a bit scary, since webapps are not supposed to be configured
in server.xml anymore, and they should be packaged in .war files, not
JARs.  You need to at least post your config, since that's likely where
the problem is.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problem deploying existing webapp in new Tomcat container

2007-05-16 Thread Rob Tanner
I meant WAR file not JAR. As far as server.xml, how else does one
specify the specifics, such as the path variable?

Here are the two application contexts:

Context crossContext=true debug=0
docBase=AccountManager
path=/accntManager reloadable=true
Logger className=org.apache.catalina.logger.FileLogger
prefix=localhost_accntmanager_log. suffix=.txt
timestamp=true/
/Context

Context crossContext=true debug=0
docBase=GroupAliases
path=/mailtools/aliases reloadable=true
Logger className=org.apache.catalina.logger.FileLogger
prefix=localhost_aliases_log. suffix=.txt
timestamp=true/
/Context

The AccountManager app works fine, but the GroupAliases generates this
error:

May 16, 2007 3:04:06 PM org.apache.catalina.core.ApplicationContext log
INFO: Marking servlet GroupAliasManager as unavailable
May 16, 2007 3:04:06 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Allocate exception for servlet GroupAliasManager
javax.servlet.ServletException: Error instantiating servlet class 
GroupAliasManager
at 
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1127)
at 
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:806)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:129)
at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at 
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261)
at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581)
at 
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)



-- Rob


Caldarale, Charles R said the following on 05/16/2007 02:32 PM:
 From: Rob Tanner [mailto:[EMAIL PROTECTED] 
 Subject: Problem deploying existing webapp in new Tomcat container

 I installed Sun Java jdk1.6.0 and apache-tomcat-6.0.13. I copied over
 the server.xml config for the first web aplication as well as the JAR
 file and everything worked fine.
 

 That sounds a bit scary, since webapps are not supposed to be configured
 in server.xml anymore, and they should be packaged in .war files, not
 JARs.  You need to at least post your config, since that's likely where
 the problem is.

  - Chuck


 THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
 MATERIAL and is thus for use only by the intended recipient. If you
 received this in error, please contact the sender and delete the e-mail
 and its attachments from all computers.

 -
 To start a new topic, e-mail: users@tomcat.apache.org
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]

   



smime.p7s
Description: S/MIME Cryptographic Signature


RE: Problem deploying existing webapp in new Tomcat container

2007-05-16 Thread Caldarale, Charles R
 From: Rob Tanner [mailto:[EMAIL PROTECTED] 
 Subject: Re: Problem deploying existing webapp in new Tomcat container
 
 As far as server.xml, how else does one specify the specifics, such as
the path variable? 
 
(Here we go again... my favorite subject :-)
 
First, read the doc:
http://tomcat.apache.org/tomcat-6.0-doc/config/context.html
 
Note the following extracts from the Introduction and the description of
the path attribute:
 
For Tomcat 6, unlike Tomcat 4.x, it is NOT recommended to place
Context elements directly in the server.xml file. This is because it
makes modifing the Context configuration more invasive since the main
conf/server.xml file cannot be reloaded without restarting Tomcat.
 
The value of this field must not be set except when statically defining
a Context in server.xml, as it will be inferred from the filenames used
for either the .xml context file or the docBase.
 
Nor should you be specifying a docBase. Put the Context elements where
they belong - in META-INF/context.xml of each webapp - and remove the
path and docBase attributes.
 
Also, reading this part of the doc:
http://tomcat.apache.org/tomcat-6.0-doc/logging.html
 
would show you that the Logger element is no longer used.
 
 - Chuck
 

THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

 



Re: Problem deploying existing webapp in new Tomcat container

2007-05-16 Thread Pid

Rob Tanner wrote:
I meant WAR file not JAR.  As far as server.xml, how else does one 
specify the specifics, such as the path variable?


Here are the two application contexts:

Context crossContext=true debug=0
docBase=AccountManager
path=/accntManager reloadable=true
  Logger className=org.apache.catalina.logger.FileLogger
 prefix=localhost_accntmanager_log. suffix=.txt
  timestamp=true/
 /Context

Context crossContext=true debug=0
docBase=GroupAliases
path=/mailtools/aliases reloadable=true
  Logger className=org.apache.catalina.logger.FileLogger
 prefix=localhost_aliases_log. suffix=.txt
  timestamp=true/
/Context


... and so the klaxons sound once again.

I'll try to beat Chuck's standard rapid fire response to this question.

Recent versions of Tomcat recommend that the Context is defined in a 
separate file in one of a couple of locations.  Read the docs at 
tomcat.apache.org for more detailed info.


If you're deploying via a WAR file you can put a context.xml file in 
META-INF, which will produce the effect you're looking for.


The context path is determined by the name of the WAR, and not the path 
attribute of the Context, (which is deprecated and only acknowledged 
when defining a Context in server.xml - seriously discouraged these days).


(N.B. There's no Logger element any more either, see the docs.)

p



The AccountManager app works fine, but the GroupAliases generates this 
error:


May 16, 2007 3:04:06 PM org.apache.catalina.core.ApplicationContext log
INFO: Marking servlet GroupAliasManager as unavailable
May 16, 2007 3:04:06 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Allocate exception for servlet GroupAliasManager
javax.servlet.ServletException: Error instantiating servlet class 
GroupAliasManager
at 
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1127)
at 
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:806)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:129)
at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at 
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261)
at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581)
at 
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)



-- Rob


Caldarale, Charles R said the following on 05/16/2007 02:32 PM:
From: Rob Tanner [mailto:[EMAIL PROTECTED] 
Subject: Problem deploying existing webapp in new Tomcat container


I installed Sun Java jdk1.6.0 and apache-tomcat-6.0.13. I copied over
the server.xml config for the first web aplication as well as the JAR
file and everything worked fine.



That sounds a bit scary, since webapps are not supposed to be configured
in server.xml anymore, and they should be packaged in .war files, not
JARs.  You need to at least post your config, since that's likely where
the problem is.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

  






smime.p7s
Description: S/MIME Cryptographic Signature


Re: Problem deploying existing webapp in new Tomcat container

2007-05-16 Thread Pid

Caldarale, Charles R wrote:
From: Rob Tanner [mailto:[EMAIL PROTECTED] 
Subject: Re: Problem deploying existing webapp in new Tomcat container
 

As far as server.xml, how else does one specify the specifics, such as
the path variable? 
 
(Here we go again... my favorite subject :-)


damn. you beat me.


First, read the doc:
http://tomcat.apache.org/tomcat-6.0-doc/config/context.html
 
Note the following extracts from the Introduction and the description of

the path attribute:
 
For Tomcat 6, unlike Tomcat 4.x, it is NOT recommended to place

Context elements directly in the server.xml file. This is because it
makes modifing the Context configuration more invasive since the main
conf/server.xml file cannot be reloaded without restarting Tomcat.
 
The value of this field must not be set except when statically defining

a Context in server.xml, as it will be inferred from the filenames used
for either the .xml context file or the docBase.
 
Nor should you be specifying a docBase. Put the Context elements where

they belong - in META-INF/context.xml of each webapp - and remove the
path and docBase attributes.
 
Also, reading this part of the doc:

http://tomcat.apache.org/tomcat-6.0-doc/logging.html
 
would show you that the Logger element is no longer used.
 
 - Chuck
 


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

 







smime.p7s
Description: S/MIME Cryptographic Signature