Re: commons-logging, Tomcat 5.5 and Hibernate 3.2

2006-10-19 Thread Dave Kennedy

Hi,
Running Tomcat "standalone" without Eclipse
Log4j logging is now configured and generating output to /logs/tomcat.log

except that struts logging is not generated ie.
Oct 19, 2006 11:24:26 AM org.apache.catalina.core.ApplicationContext log
INFO: action: Processing a POST for /cancel

Does struts logging need to be configured in Log4j?

==
log4j.properties
==
### Tomcat
#log4j.rootLogger=debug, R
log4j.rootLogger=info, R
log4j.appender.R=org.apache.log4j.RollingFileAppender
log4j.appender.R.File=${catalina.home}/logs/tomcat.log
log4j.appender.R.MaxFileSize=10MB
log4j.appender.R.MaxBackupIndex=10
log4j.appender.R.layout=org.apache.log4j.PatternLayout
log4j.appender.R.layout.ConversionPattern=%p %t %c - %m%n
log4j.logger.org.apache.catalina=info, R
#log4j.logger.org.apache.catalina=DEBUG, R
### direct log messages to stdout ###
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.Target=System.out
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - 
%m%n


### direct messages to file hibernate.log ###
#log4j.appender.file=org.apache.log4j.FileAppender
#log4j.appender.file.File=hibernate.log
#log4j.appender.file.layout=org.apache.log4j.PatternLayout
#log4j.appender.file.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - 
%m%n


### set log levels - for more verbose logging change 'info' to 'debug' ###

#log4j.rootLogger=warn, stdout

log4j.logger.org.hibernate=info
#log4j.logger.org.hibernate=debug

### log HQL query parser activity
#log4j.logger.org.hibernate.hql.ast.AST=debug

### log just the SQL
#log4j.logger.org.hibernate.SQL=debug

### log JDBC bind parameters ###
log4j.logger.org.hibernate.type=info
#log4j.logger.org.hibernate.type=debug

### log schema export/update ###
log4j.logger.org.hibernate.tool.hbm2ddl=debug



From: "Boris Unckel" <[EMAIL PROTECTED]>
Reply-To: "Tomcat Users List" 
To: "Tomcat Users List" 
Subject: Re: commons-logging, Tomcat 5.5 and Hibernate 3.2
Date: Fri, 20 Oct 2006 08:34:49 +0200

Hello,

> The issue seems to be with commons-logging, Tomcat and Hibernate
>
> There are lot of articles on the Web on this but I still can't resolve
> this
> Anyone have Hibernate 3.2 and Tomcat 5.5 logging with commons-logging?
> >
> >Hi,
> >ENV1: Struts 1.2.9, Tomcat 5.5, Eclipse 3.2.0
> >ENV2: Struts 1.2.9, Tomcat 5.5, Eclipse 3.2.0, Hibernate 3.1
> >
> >The info below is logged to Tomcat in ENV1 but not ENV2.
> >How is Tomcat configured to log info?

this may be caused by the Eclipse startup of Tomcat. Try the same 
"standalone" without Eclipse. If you still have problems check the path and 
versions of commons-logging(JCL), update to JCL1.1 and enable the 
diagnostics:

http://jakarta.apache.org/commons/logging/troubleshooting.html#Using_JCL_Diagnostics

Regards
Boris

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



_
Ready for the world's first international mobile film festival celebrating 
the creative potential of today's youth? Check out Mobile Jam Fest for your 
a chance to WIN $10,000! www.mobilejamfest.com



-
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: commons-logging, Tomcat 5.5 and Hibernate 3.2

2006-10-19 Thread Michael Courcy
Tomcat use commons.logging, so you can choose either java.util.logging 
or Log4J ,

http://tomcat.apache.org/tomcat-5.5-doc/logging.html
But hibernate use Log4J
http://www.hibernate.org/97.html

I permanantly use Tomcat/hibenate/Spring without any logging issue ?

Here is my log4j.properties

# Global logging configuration
log4j.rootLogger=INFO, stdout

# configuration...
org.apache.commons.digester.Digester=INFO

# Console output...
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%5p [%t] - %m%n

Put it somewhere in your classPath (like in the WEB-INF/classes 
directory) and all the logs should drop in catalina.out.


Hope this helps.


Mic.

You should have
ave Kennedy a écrit :

The issue seems to be with commons-logging, Tomcat and Hibernate

There are lot of articles on the Web on this but I still can't resolve 
this

Anyone have Hibernate 3.2 and Tomcat 5.5 logging with commons-logging?


From: "Dave Kennedy" <[EMAIL PROTECTED]>
Reply-To: "Tomcat Users List" 
To: users@tomcat.apache.org
Subject: How to log INFO in Tomcat
Date: Thu, 19 Oct 2006 14:14:46 -0700

Hi,
ENV1: Struts 1.2.9, Tomcat 5.5, Eclipse 3.2.0
ENV2: Struts 1.2.9, Tomcat 5.5, Eclipse 3.2.0, Hibernate 3.1

The info below is logged to Tomcat in ENV1 but not ENV2.
How is Tomcat configured to log info?

log/localhost.2006-10-19.log
...
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action: Processing a POST for /process
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Looking for ActionForm bean under attribute 'detailForm'
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Creating new ActionForm instance of class 
'action.DetailForm'

Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Storing instance under attribute 'detailForm' in scope 
'request'

Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Populating bean properties from this request
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Validating input form properties
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Looking for Action instance for class 
action.ProcessDVDAction

Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:   Double checking for Action instance already there
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:   Creating new Action instance
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action: Processing a POST for /cancel

_
Ready for the world's first international mobile film festival 
celebrating the creative potential of today's youth? Check out Mobile 
Jam Fest for your a chance to WIN $10,000! www.mobilejamfest.com



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



_
Experience Live Search from your PC or mobile device today. 
http://www.live.com/?mkt=en-ca



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





-
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: IPTABLES

2006-10-19 Thread Gaël Lams

Im running a tomcat in port 80 without httpd
I want redirect packages from 80 to 8080 because tomcat is running as
tomcat user (cant run as other non root under port 1025) and I tried the
IPTABLES redirection aproach but doesnt work


I performed the same setup to have tomcat running on 8080 but users
connecting on port 80. The following should work:

# Forward request from port 80 to tomcat listening on port 8080
# REDIRECT is a specialized case of Destination NAT: it is exactly
equivalent to doing DNAT to the address of the incoming interface.
# as with DNAT, it can be used only in PREROUTING and OUTPUT
iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-ports 8080

# PREROUTING happens before INPUT, therefore the INPUT rule needs to
allow the translated packet, not the original one.
iptables -A INPUT -p tcp --dport 8080 -j ACCEPT

Regards,

Gaël


Re: commons-logging, Tomcat 5.5 and Hibernate 3.2

2006-10-19 Thread Boris Unckel
Hello,

> The issue seems to be with commons-logging, Tomcat and Hibernate
> 
> There are lot of articles on the Web on this but I still can't resolve
> this
> Anyone have Hibernate 3.2 and Tomcat 5.5 logging with commons-logging?
> >
> >Hi,
> >ENV1: Struts 1.2.9, Tomcat 5.5, Eclipse 3.2.0
> >ENV2: Struts 1.2.9, Tomcat 5.5, Eclipse 3.2.0, Hibernate 3.1
> >
> >The info below is logged to Tomcat in ENV1 but not ENV2.
> >How is Tomcat configured to log info?

this may be caused by the Eclipse startup of Tomcat. Try the same "standalone" 
without Eclipse. If you still have problems check the path and versions of 
commons-logging(JCL), update to JCL1.1 and enable the diagnostics:
http://jakarta.apache.org/commons/logging/troubleshooting.html#Using_JCL_Diagnostics

Regards
Boris

-
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 an Application

2006-10-19 Thread Li

Hi,

Try to re-install tomcat ... wish it works

Li

On 10/20/06, Marco Aurélio S. Silva <[EMAIL PROTECTED]> wrote:


Hi,

I discover some thing new about the problem...

This application is using a jar file that have the ServletContextListener,
and it's used by the web application, til monday this was working ok, and
still working on my PC and in other servers, but one of them is given the
problem

When I use the class implementing ServletContextListener in the web
application it works OK, but when I use the class that implements
ServletContextListener in the JAR file, I got the stack that I sent...

It's correct what I'm doing??? I do this becuse I have two application
that
use the same ServletContextListener

Thanks,

--
Marco Aurélio S. Silva
[EMAIL PROTECTED]




2006/10/19, Marco Aurélio S. Silva <[EMAIL PROTECTED]>:
>
> Hi Li,
>
> I checked and the javax/servlet/http/HttpServletRequest is in the jar, I
> had try to change the jar and nothing happens...
>
> I write a simple test page and everything run correctly...
>
> I use the same war file in other server, and it deploys and run, only on
> this server I'm having problem I try to deploy the probe application
and
> the same problem occurs..
>
> Thanks,
>
> --
> Marco Aurélio S. Silva
> [EMAIL PROTECTED]
>
>
>  2006/10/19, Li <[EMAIL PROTECTED]>:
> >
> > If so, I dont see any problem for your tomcat since some webapp can be
> > deployed without any problem.
> >
> > Can you check:
> > 1. there is javax/servlet/http/HttpServletRequest in your servlet jar
> > (under
> > common), do not place it in your WEB-INF/lib
> > 2. you can write a very simple test page as home page for the webapp
you
> > r
> > going to deploy, see if there is any problem
> >
> > wish it helps, good luck
> >
> > On 10/19/06, Marco Aurélio S. Silva <[EMAIL PROTECTED]> wrote:
> > >
> > > The both are ok! I have some applications running well and some
> > give
> > > me
> > > this problem
> > >
> > >
> > >
> > > 2006/10/19, Li <[EMAIL PROTECTED]>:
> > > >
> > > > It looks like servlet jar can not be found, if your class path
> > setting
> > > is
> > > > ok, make sure the permission is ok
> > > >
> > > >
> > > > On 10/19/06, Marco Aurélio S. Silva < [EMAIL PROTECTED]>
> > wrote:
> > > > >
> > > > > Hi folks,
> > > > >
> > > > > I'm trying to deploy an application on my Tomcat 5.5.9 under a
> > Windows
> > > > > 2003
> > > > > Server with JVM 1.5.0_04, and get the following stack error:
> > > > >
> > > > > 19/Out/2006 11:02:13
> > > org.apache.catalina.core.StandardWrapperValveinvoke
> > > > > SEVERE: Servlet.service() for servlet HTMLManager threw
exception
> > > > > java.lang.NoClassDefFoundError:
> > javax/servlet/http/HttpServletRequest
> > > > > at
> > > > >
> > > >
> > >
> >
org.apache.commons.fileupload.servlet.ServletRequestContext.getContentType
> > > > > (
> > > > > ServletRequestContext.java:72)
> > > > > at org.apache.commons.fileupload.FileUploadBase.parseRequest (
> > > > > FileUploadBase.java:290)
> > > > > at org.apache.commons.fileupload.FileUploadBase.parseRequest(
> > > > > FileUploadBase.java:268)
> > > > > at org.apache.catalina.manager.HTMLManagerServlet.doPost (
> > > > > HTMLManagerServlet.java:157)
> > > > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
> > > > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> > > > > at
> > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> > > > > ApplicationFilterChain.java:252)
> > > > > at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> > > > > ApplicationFilterChain.java :173)
> > > > > at org.apache.catalina.core.StandardWrapperValve.invoke(
> > > > > StandardWrapperValve.java:213)
> > > > > at org.apache.catalina.core.StandardContextValve.invoke(
> > > > > StandardContextValve.java:178)
> > > > > at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
> > > > > AuthenticatorBase.java:482)
> > > > > at org.apache.catalina.core.StandardHostValve.invoke (
> > > > > StandardHostValve.java
> > > > > :126)
> > > > > at org.apache.catalina.valves.ErrorReportValve.invoke(
> > > > > ErrorReportValve.java
> > > > > :105)
> > > > > at org.apache.catalina.core.StandardEngineValve.invoke(
> > > > > StandardEngineValve.java:107)
> > > > > at org.apache.catalina.connector.CoyoteAdapter.service(
> > > > CoyoteAdapter.java
> > > > > :148)
> > > > > at org.apache.coyote.http11.Http11Processor.process(
> > > Http11Processor.java
> > > > > :856)
> > > > > at
> > > > >
> > > > >
> > > >
> > >
> >
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection
> > > > > (Http11Protocol.java:744)
> > > > > at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(
> > > > > PoolTcpEndpoint.java:527)
> > > > > at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt (
> > > > > LeaderFollowerWorkerThread.java:80)
> > > > > at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run
(
> > > > > ThreadPool.java:684)
> > > > > at java

commons-logging, Tomcat 5.5 and Hibernate 3.2

2006-10-19 Thread Dave Kennedy

The issue seems to be with commons-logging, Tomcat and Hibernate

There are lot of articles on the Web on this but I still can't resolve this
Anyone have Hibernate 3.2 and Tomcat 5.5 logging with commons-logging?


From: "Dave Kennedy" <[EMAIL PROTECTED]>
Reply-To: "Tomcat Users List" 
To: users@tomcat.apache.org
Subject: How to log INFO in Tomcat
Date: Thu, 19 Oct 2006 14:14:46 -0700

Hi,
ENV1: Struts 1.2.9, Tomcat 5.5, Eclipse 3.2.0
ENV2: Struts 1.2.9, Tomcat 5.5, Eclipse 3.2.0, Hibernate 3.1

The info below is logged to Tomcat in ENV1 but not ENV2.
How is Tomcat configured to log info?

log/localhost.2006-10-19.log
...
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action: Processing a POST for /process
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Looking for ActionForm bean under attribute 'detailForm'
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Creating new ActionForm instance of class 
'action.DetailForm'

Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Storing instance under attribute 'detailForm' in scope 
'request'

Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Populating bean properties from this request
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Validating input form properties
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Looking for Action instance for class 
action.ProcessDVDAction

Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:   Double checking for Action instance already there
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:   Creating new Action instance
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action: Processing a POST for /cancel

_
Ready for the world's first international mobile film festival celebrating 
the creative potential of today's youth? Check out Mobile Jam Fest for your 
a chance to WIN $10,000! www.mobilejamfest.com



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



_
Experience Live Search from your PC or mobile device today. 
http://www.live.com/?mkt=en-ca



-
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: problems with unpacking ROOT.war

2006-10-19 Thread Caldarale, Charles R
> From: Rizalino DeVilleres [mailto:[EMAIL PROTECTED] 
> Subject: RE: problems with unpacking ROOT.war
> 
> Is there another work around to get them both working? I believe, this
> is the same setup we've had on the previous versions of Tomcat, we
> simply want to place all the war/JSPs files in the public_html and
> servlets as mentioned above.

The intent of the Servlet and JSP specs is to define the environment for
execution of web _applications_, not arbitrary JSP files.  All JSP files
must be part of some context; you can use ROOT if no other context is
appropriate.  By default, each subdirectory and war file under the
host's appBase should be a deployable webapp, using the file structure
defined by the servlet spec.  Tomcat lets you avoid building such a file
structure if you place a  element in the
conf/[engine]/[host]/[appname].xml file.

If I intrepreted your requirements properly, you should try the
following:

1) Specify "/path/to/public_html" as your host's appBase.

2) Put your ROOT.xml in conf/[engine]/[host] specifying a docBase of
"servlet".

3) Place your unassociated JSP files in the /path/to/public_html/servlet
directory.

4) Put your war files or app directories (expanded wars) in the
/path/to/public_html directory (NOT /path/to/public_html/servlet).  The
name of each subdirectory or war file becomes the URI path to the app.

5) Do not put a WEB-INF subdirectory under /path/to/public_htmi/servlet,
unless you want the contents of that subdirectory deployed as both the
default app and "servlet".

 - 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: Stopping Tomcat

2006-10-19 Thread Parsons Technical Services

One approach that would work with any app is to use a set of lock files.

Set a lock file say TomcatStart at the beginning of the start script.
Delete it and set a TomcatRun file upon completion of the start script.
Check for the presence of the files in the Java application.
TomcatStart exists: Tomcat is starting hold your horses.
TomcatRun exists: Kill at will.
Neither file exists: Dead already.

You may be able to use some of the existing code in the startup and shutdown 
scripts that come with Tomcat.


As for a class to call I do not know but am sure someone on the list will.

Doug


- Original Message - 
From: "Miguel Correia Ricardo" <[EMAIL PROTECTED]>

To: 
Sent: Thursday, October 19, 2006 12:56 PM
Subject: Stopping Tomcat



Hello,

I'm having problems in stopping Tomcat. More precisely stopping
Tomcat, while is starting. I want to be able to check the status of a
running instance of Tomcat, and be able to wait, before sending the
shutdown command (all this in a Java application), otherwise Tomcat
throws an exception, or sends a message stating that catalina engine
has not started yet. So, my question is, does anyone know some class
that exists in tomcat that enables me to check
it's status?
I would appreciate any help.
Best regards,
Miguel Correia Ricardo

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







-
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: IPTABLES

2006-10-19 Thread Parsons Technical Services

So, if I read correctly you have no problems running you apps as root?

If this is true, then I say you have a very weak security posture.

Might I suggest you do some additional research on the subject. And that 
those who run things in a chroot jail must be real paranoid freaks.


And now this post is way off topic.

Doug


- Original Message - 
From: "Paul Singleton" <[EMAIL PROTECTED]>

To: "Tomcat Users List" 
Sent: Thursday, October 19, 2006 7:21 PM
Subject: Re: IPTABLES



Christopher Schultz wrote:


Apache httpd is configured out of the box to start up as root, bind to
port 80 (or really any port), and then drop its privileges to the httpd
user. Without some really nasty code, Tomcat is unable to do the same
thing, so we're forced to do silly things like internal port forwarding,
etc.


The "root-only-access-to-low-ports" policy of
Linux is a legacy from the days when Unix systems
were typically multi-user: it is a heavy-handed way
of stopping the oiks from running unauthorised
servers.

In a secure server it is unnecessary, indeed
counterproductive when it tempts us to run services
as root, or to use tricksy workarounds.

Linux should make this switch-offable (without
having to recompile the kernel).

The only problem I've found with standalone Tomcat
plus iptables port forwarding (apart from the need
to understand iptables :-)) is that web apps can't
make requests to themselves at port 80, but have to
use 8080 or whatever.

Paul Singleton

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







-
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 an Application

2006-10-19 Thread Marco Aurélio S. Silva

Hi Li,

I checked and the javax/servlet/http/HttpServletRequest is in the jar, I had
try to change the jar and nothing happens...

I write a simple test page and everything run correctly...

I use the same war file in other server, and it deploys and run, only on
this server I'm having problem I try to deploy the probe application and
the same problem occurs..

Thanks,

--
Marco Aurélio S. Silva
[EMAIL PROTECTED]


2006/10/19, Li <[EMAIL PROTECTED]>:


If so, I dont see any problem for your tomcat since some webapp can be
deployed without any problem.

Can you check:
1. there is javax/servlet/http/HttpServletRequest in your servlet jar
(under
common), do not place it in your WEB-INF/lib
2. you can write a very simple test page as home page for the webapp you r
going to deploy, see if there is any problem

wish it helps, good luck

On 10/19/06, Marco Aurélio S. Silva <[EMAIL PROTECTED]> wrote:
>
> The both are ok! I have some applications running well and some give
> me
> this problem
>
>
>
> 2006/10/19, Li <[EMAIL PROTECTED]>:
> >
> > It looks like servlet jar can not be found, if your class path setting
> is
> > ok, make sure the permission is ok
> >
> >
> > On 10/19/06, Marco Aurélio S. Silva <[EMAIL PROTECTED]> wrote:
> > >
> > > Hi folks,
> > >
> > > I'm trying to deploy an application on my Tomcat 5.5.9 under a
Windows
> > > 2003
> > > Server with JVM 1.5.0_04, and get the following stack error:
> > >
> > > 19/Out/2006 11:02:13
> org.apache.catalina.core.StandardWrapperValveinvoke
> > > SEVERE: Servlet.service() for servlet HTMLManager threw exception
> > > java.lang.NoClassDefFoundError:
javax/servlet/http/HttpServletRequest
> > > at
> > >
> >
>
org.apache.commons.fileupload.servlet.ServletRequestContext.getContentType
> > > (
> > > ServletRequestContext.java:72)
> > > at org.apache.commons.fileupload.FileUploadBase.parseRequest(
> > > FileUploadBase.java:290)
> > > at org.apache.commons.fileupload.FileUploadBase.parseRequest(
> > > FileUploadBase.java:268)
> > > at org.apache.catalina.manager.HTMLManagerServlet.doPost(
> > > HTMLManagerServlet.java:157)
> > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
> > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> > > at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> > > ApplicationFilterChain.java:252)
> > > at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> > > ApplicationFilterChain.java:173)
> > > at org.apache.catalina.core.StandardWrapperValve.invoke(
> > > StandardWrapperValve.java:213)
> > > at org.apache.catalina.core.StandardContextValve.invoke(
> > > StandardContextValve.java:178)
> > > at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
> > > AuthenticatorBase.java:482)
> > > at org.apache.catalina.core.StandardHostValve.invoke(
> > > StandardHostValve.java
> > > :126)
> > > at org.apache.catalina.valves.ErrorReportValve.invoke(
> > > ErrorReportValve.java
> > > :105)
> > > at org.apache.catalina.core.StandardEngineValve.invoke(
> > > StandardEngineValve.java:107)
> > > at org.apache.catalina.connector.CoyoteAdapter.service(
> > CoyoteAdapter.java
> > > :148)
> > > at org.apache.coyote.http11.Http11Processor.process(
> Http11Processor.java
> > > :856)
> > > at
> > >
> > >
> >
>
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection
> > > (Http11Protocol.java:744)
> > > at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(
> > > PoolTcpEndpoint.java:527)
> > > at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(
> > > LeaderFollowerWorkerThread.java:80)
> > > at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(
> > > ThreadPool.java:684)
> > > at java.lang.Thread.run(Unknown Source)
> > >
> > > I was looking for how to solve it, and find that it seems to be a
> > problem
> > > on
> > > the ClassLoader, and only a new installation of the Tomcat solve it!
> Is
> > > that
> > > true or there is another way to solve it?
> > >
> > > I checked the servlet-api.jar and it's ok!
> > >
> > > Thanks,
> > >
> > > --
> > > Marco Aurélio S. Silva
> > > [EMAIL PROTECTED]
> > >
> > >
> >
> >
> > --
> > When we invent time, we invent death.
> >
> >
>
>
> --
> Marco Aurélio S. Silva
> [EMAIL PROTECTED]
>
>


--
When we invent time, we invent death.




Re: IPTABLES

2006-10-19 Thread Paul Singleton

Christopher Schultz wrote:


Apache httpd is configured out of the box to start up as root, bind to
port 80 (or really any port), and then drop its privileges to the httpd
user. Without some really nasty code, Tomcat is unable to do the same
thing, so we're forced to do silly things like internal port forwarding,
etc.


The "root-only-access-to-low-ports" policy of
Linux is a legacy from the days when Unix systems
were typically multi-user: it is a heavy-handed way
of stopping the oiks from running unauthorised
servers.

In a secure server it is unnecessary, indeed
counterproductive when it tempts us to run services
as root, or to use tricksy workarounds.

Linux should make this switch-offable (without
having to recompile the kernel).

The only problem I've found with standalone Tomcat
plus iptables port forwarding (apart from the need
to understand iptables :-)) is that web apps can't
make requests to themselves at port 80, but have to
use 8080 or whatever.

Paul Singleton

-
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 an Application

2006-10-19 Thread Marco Aurélio S. Silva

Hi,

I discover some thing new about the problem...

This application is using a jar file that have the ServletContextListener,
and it's used by the web application, til monday this was working ok, and
still working on my PC and in other servers, but one of them is given the
problem

When I use the class implementing ServletContextListener in the web
application it works OK, but when I use the class that implements
ServletContextListener in the JAR file, I got the stack that I sent...

It's correct what I'm doing??? I do this becuse I have two application that
use the same ServletContextListener

Thanks,

--
Marco Aurélio S. Silva
[EMAIL PROTECTED]




2006/10/19, Marco Aurélio S. Silva <[EMAIL PROTECTED]>:


Hi Li,

I checked and the javax/servlet/http/HttpServletRequest is in the jar, I
had try to change the jar and nothing happens...

I write a simple test page and everything run correctly...

I use the same war file in other server, and it deploys and run, only on
this server I'm having problem I try to deploy the probe application and
the same problem occurs..

Thanks,

--
Marco Aurélio S. Silva
[EMAIL PROTECTED]


 2006/10/19, Li <[EMAIL PROTECTED]>:
>
> If so, I dont see any problem for your tomcat since some webapp can be
> deployed without any problem.
>
> Can you check:
> 1. there is javax/servlet/http/HttpServletRequest in your servlet jar
> (under
> common), do not place it in your WEB-INF/lib
> 2. you can write a very simple test page as home page for the webapp you
> r
> going to deploy, see if there is any problem
>
> wish it helps, good luck
>
> On 10/19/06, Marco Aurélio S. Silva <[EMAIL PROTECTED]> wrote:
> >
> > The both are ok! I have some applications running well and some
> give
> > me
> > this problem
> >
> >
> >
> > 2006/10/19, Li <[EMAIL PROTECTED]>:
> > >
> > > It looks like servlet jar can not be found, if your class path
> setting
> > is
> > > ok, make sure the permission is ok
> > >
> > >
> > > On 10/19/06, Marco Aurélio S. Silva < [EMAIL PROTECTED]>
> wrote:
> > > >
> > > > Hi folks,
> > > >
> > > > I'm trying to deploy an application on my Tomcat 5.5.9 under a
> Windows
> > > > 2003
> > > > Server with JVM 1.5.0_04, and get the following stack error:
> > > >
> > > > 19/Out/2006 11:02:13
> > org.apache.catalina.core.StandardWrapperValveinvoke
> > > > SEVERE: Servlet.service() for servlet HTMLManager threw exception
> > > > java.lang.NoClassDefFoundError:
> javax/servlet/http/HttpServletRequest
> > > > at
> > > >
> > >
> >
> org.apache.commons.fileupload.servlet.ServletRequestContext.getContentType
> > > > (
> > > > ServletRequestContext.java:72)
> > > > at org.apache.commons.fileupload.FileUploadBase.parseRequest (
> > > > FileUploadBase.java:290)
> > > > at org.apache.commons.fileupload.FileUploadBase.parseRequest(
> > > > FileUploadBase.java:268)
> > > > at org.apache.catalina.manager.HTMLManagerServlet.doPost (
> > > > HTMLManagerServlet.java:157)
> > > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
> > > > at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> > > > at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> > > > ApplicationFilterChain.java:252)
> > > > at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> > > > ApplicationFilterChain.java :173)
> > > > at org.apache.catalina.core.StandardWrapperValve.invoke(
> > > > StandardWrapperValve.java:213)
> > > > at org.apache.catalina.core.StandardContextValve.invoke(
> > > > StandardContextValve.java:178)
> > > > at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
> > > > AuthenticatorBase.java:482)
> > > > at org.apache.catalina.core.StandardHostValve.invoke (
> > > > StandardHostValve.java
> > > > :126)
> > > > at org.apache.catalina.valves.ErrorReportValve.invoke(
> > > > ErrorReportValve.java
> > > > :105)
> > > > at org.apache.catalina.core.StandardEngineValve.invoke(
> > > > StandardEngineValve.java:107)
> > > > at org.apache.catalina.connector.CoyoteAdapter.service(
> > > CoyoteAdapter.java
> > > > :148)
> > > > at org.apache.coyote.http11.Http11Processor.process(
> > Http11Processor.java
> > > > :856)
> > > > at
> > > >
> > > >
> > >
> >
> 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection
> > > > (Http11Protocol.java:744)
> > > > at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(
> > > > PoolTcpEndpoint.java:527)
> > > > at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt (
> > > > LeaderFollowerWorkerThread.java:80)
> > > > at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(
> > > > ThreadPool.java:684)
> > > > at java.lang.Thread.run(Unknown Source)
> > > >
> > > > I was looking for how to solve it, and find that it seems to be a
> > > problem
> > > > on
> > > > the ClassLoader, and only a new installation of the Tomcat solve
> it!
> > Is
> > > > that
> > > > true or there is another way to solve it?
> > > >
> > > > I checked the servlet-api.jar and it's ok!
>

How to log INFO in Tomcat

2006-10-19 Thread Dave Kennedy

Hi,
ENV1: Struts 1.2.9, Tomcat 5.5, Eclipse 3.2.0
ENV2: Struts 1.2.9, Tomcat 5.5, Eclipse 3.2.0, Hibernate 3.1

The info below is logged to Tomcat in ENV1 but not ENV2.
How is Tomcat configured to log info?

log/localhost.2006-10-19.log
...
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action: Processing a POST for /process
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Looking for ActionForm bean under attribute 'detailForm'
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Creating new ActionForm instance of class 'action.DetailForm'
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Storing instance under attribute 'detailForm' in scope 
'request'

Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Populating bean properties from this request
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Validating input form properties
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:  Looking for Action instance for class action.ProcessDVDAction
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:   Double checking for Action instance already there
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action:   Creating new Action instance
Oct 19, 2006 1:20:31 PM org.apache.catalina.core.ApplicationContext log
INFO: action: Processing a POST for /cancel

_
Ready for the world's first international mobile film festival celebrating 
the creative potential of today's youth? Check out Mobile Jam Fest for your 
a chance to WIN $10,000! www.mobilejamfest.com



-
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: Tomcat, Apache and mod_jk configuration

2006-10-19 Thread Michael Courcy
Yes it looks much more powerful than my solution. Especially if you want 
to guarantee a minimum JVM heap size for each app.


Thanks a lot.

JVM
It looks like what to have more than one webapp as the "root webapp".

My suggestion would be to run each webapp in a different instance of
Tomcat. It's much easier than you think is it to do this. I use Tomcat
4.1.x, but I'm sure the same is possible with very few changes on 5.5.x:

1. Create a directory structure for each webapp (outside of Tomcat's
installation directory) like this:

struts-dev-1/
struts-dev-1/conf
struts-dev-1/conf/server.xml
struts-dev-1/conf/web.xml
struts-dev-1/webapps
struts-dev-1/logs
struts-dev-1/temp

** Make sure to set your port numbers for your shutdown and connector
ports to something unique among your webapps. I usually use 8x85 for the
ajp13 connector port and 8x86 for the shutdown port.

2. Install your webapp to the directory struts-dev-1/webapps/struts-dev-1

3. Configure Tomcat to use "struts-dev-1" as your root webapp (usually
by specifying that the "path" is "" instead of "/struts-dev-1").

4. Start each Tomcat instance like this:

$ export JAVA_HOME=...
$ export CATALINA_HOME=/path/to/full/tomcat/install
$ export CATALINA_BASE=/path/to/struts-dev-1
$ export CATALINA_TMPDIR=/path/th/struts-dev-1/temp
$ /path/to/full/tomcat/install/bin/startup.sh

This setup allows you to have separate root webapps (or any other kind
of setup). You also have the benefit (I choose to see it as a benefit)
of separate JVMs and Tomcat instances. You can take one down without
bothering the others.

Hope that helps,
-chris


  




Re: Tomcat, Apache and mod_jk configuration

2006-10-19 Thread Michael Courcy

Yes it's what I mean,

in your JkMount declaration change

jkMount /struts-dev-1/*.do ajp13
jkMount /struts-dev-1/*.jsp ajp13

By 


jkMount /*.do ajp13
jkMount /*.jsp ajp13

And your server.xml fragment should look this way



  



It should works.





DE VINZELLES, Guillaume (ext.) a écrit :

In fact, I've already put the jkMount directive in the VirtualHost conf.
It looks like:


DocumentRoot "/var/www/preprod.skyce.net/htdocs"

Options Indexes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all

ServerName preprod.skyce.net
ErrorLog /var/www/preprod.skyce.net/log/error_log
CustomLog /var/www/preprod.skyce.net/log/access_log common
jkMount /struts-dev-1/*.do ajp13
jkMount /struts-dev-1/*.jsp ajp13


And I'd like to have my webapp accessible through http://preprod.skyce.net/ 
instead of http://preprod.skyce.net/struts-dev-1/.

The pertinent fragment of my server.xml is:



My webapps are located in /var/tomcat/webapps, and I got:
CATALINA_BASE: /var/tomcat and CATALINA_HOME: /opt/tomcat5

Thanks !

Guillaume de Vinzelles
DSI/PFS Neuf Cegetel
Altran Technologies
 
[EMAIL PROTECTED]
 
01 70 18 21 64


-Message d'origine-
De : Michael Courcy [mailto:[EMAIL PROTECTED] 
Envoyé : jeudi 19 octobre 2006 14:51

À : Tomcat Users List
Objet : Re: Tomcat, Apache and mod_jk configuration

Hello

Here is a fragment of my server.xml



 verlina.com
 tique-et-puce.fr
 www.tique-et-puce.fr
 shampooing-chien.fr
 www.shampooing-chien.fr



 directory="logs"  prefix="verlina.com_access_log." 
suffix=".txt"

 pattern="common" resolveHosts="false"/>

className="org.apache.catalina.valves.FastCommonAccessLogValve"
 directory="logs"  prefix="verlina.com_access_log." 
suffix=".txt"

 pattern="common" resolveHosts="false"/>


type="javax.sql.DataSource"

 maxActive="100" maxIdle="30" maxWait="1"
  removeAbandoned="true" removeAbandonedTimeout="60" 
logAbandoned="true"

 username="***" password=""
driverClassName="com.mysql.jdbc.Driver"

url="jdbc:mysql://localhost:3306/verlina_com?autoReconnect=true"/>

 

 

And here is a fragment of my httpd.conf


ServerName www.verlina.com
ServerAlias verlina.com
ServerAlias tique-et-puce.fr
ServerAlias www.tique-et-puce.fr
ServerAlias shampooing-chien.fr
ServerAlias www.shampooing-chien.fr

JkMount /* ajp13

ServerAdmin [EMAIL PROTECTED]
#DocumentRoot /home/verlina/www
User verlina
Group users

CustomLog logs/verlina-access_log combined
ScriptAlias /cgi-bin/ /home/verlina/cgi-bin/


The idea is to put the JkMount inside the virtualHost of Apache.

But discussing with Mr Caldarale, this layout is weak, even if it works.

Because if you make any change to the context, you're forced to restart 
tomcat instead of just redeploying your context.


There should be a way for your app to programatticly communicate to 
tomcat  the list of domain the app should handle, but I don't know how 
to do that.


Cheers.




DE VINZELLES, Guillaume (ext.) a écrit :
  

Hi there,

Here is my problem. I got a working Tomcat 5.5.20 handling 4 webapps in 
/var/tomcat/webapps. I got a working Apache 2, configured with several 
virtualhosts.
I managed to connect the Apache to the Tomcat using an AJP13 connector, and 
everything is working fine.
Now, I'd like to map each one of my webapps to a different virtualhost.
For instance, I'd like that my webapp example1, which is in 
/var/tomcat/webapps/example1, should be accessible through www.example1.com 
(and NOT www.example1.com/example1 - I've already that working).
How do you achieve this using the jkMount directives?
I've tried with jkMount /example1/* ajp13 and my webapp is accessible only 
through www.example1.com/example1.

Thanks in advance for your answers!

Guillaume de Vinzelles
DSI/PFS Neuf Cegetel
Altran Technologies
 
[EMAIL PROTECTED]
 
01 70 18 21 64



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


  




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


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


  



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

Re: running tomcat 5.5 as a service on 64bit windows

2006-10-19 Thread joon yoo

so awesome, thank you very much.

joon

On 10/15/06, Mladen Turk <[EMAIL PROTECTED]> wrote:


joon yoo wrote:
> Hello,
>
> Is there a way to run tomcat 5.5 as a service on Win 2003 64bit?  Or is
> there a 3rd party app monitor that can start tomcat if it detects that
it's
> down.
>

http://svn.apache.org/viewvc/tomcat/connectors/trunk/procrun/bin/

Download
tomcat5.exe.amd64 and rename to tomcat5.exe

If using installer just replace the installed
tomcat5.exe with this 64-bit version.
(as well as tomcat5w.exe.amd64 for a monitor)

Anyhow, we are working on the installer that will
install the 'native' version of the tomcat5.exe
depending on the OS.

Regards,
Mladen.

-
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: URL mapping without multiple initialization

2006-10-19 Thread Caldarale, Charles R
> From: Iacopo Savoia [mailto:[EMAIL PROTECTED] 
> Subject: URL mapping without multiple initialization
> 
> I have a standalone Tomcat 5.5 and
> I am not able to figure out how to map multiple url
> to the same webapp without having tomcat initialize
> the webapp twice.

Two possibilities come immediately to mind:

1) Have all but one of the webapps be dummies that do nothing but
forward the request to the real one.

2) Configure a valve to modify the request as it comes in so it accesses
the one deployed webapp.  See:
http://tomcat.apache.org/tomcat-5.5-doc/config/valve.html
(Such a mechanism would not be portable to other containers.)

There are probably other means as well.

 - 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]



URL mapping without multiple initialization

2006-10-19 Thread Iacopo Savoia

I have a standalone Tomcat 5.5 and
I am not able to figure out how to map multiple url
to the same webapp without having tomcat initialize
the webapp twice.

I have an webapp deployed in webapps/testapp

This is accessible through http://localhost/testapp

Now I want to access the same webapp using an
alternate url like: http://localhost/foo.

I defined a new context in server.xml like:


   

but now I see that the webapp is initialized
twice by tomcat. How can I have only one
initialization of my webapp ?

Thanks

Iacopo

_
All-in-one security and maintenance for your PC.  Get a free 90-day trial! 
http://clk.atdmt.com/MSN/go/msnnkwlo005002msn/direct/01/?href=http://www.windowsonecare.com/?sc_cid=msn_hotmail



-
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: moving the context xml from $CATALINA_BASE/conf/

2006-10-19 Thread Caldarale, Charles R
> From: Molina, Teresa [mailto:[EMAIL PROTECTED] 
> Subject: RE: moving the context xml from $CATALINA_BASE/conf/
> 
> we had configured a default context to define the jdbc connections 
> commonly used by our multiple webapps (we are running more than a 
> dozen webapps under one Tomcat JVM, basically all using the same DB 
> connection resources). Previously, the context element
> (defaultContext) was contained within the server.xml itself, and we 
> were able to place that xml file in multiple paths on our system, 
> using the "-config {path}" option when calling startup.sh.

Can you accomplish the same thing by using  elements in
conf/context.xml, and then placing an appropriate
 element in each server.xml, as specified by
-config?  Take a look at:
http://tomcat.apache.org/tomcat-5.5-doc/config/globalresources.html

 - 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]



Administrate Tomcats in a cluster

2006-10-19 Thread ying lcs

Hi,

I am running multiple Tomcats in a cluster.  Can you please tell me if
I can have a single admin console which administrate the whole
cluster? e.g. load a war file across the whole cluster? or change the
configuration  of Tomcat across the whole cluster?

Thank you.

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



Stopping Tomcat

2006-10-19 Thread Miguel Correia Ricardo

Hello,

I'm having problems in stopping Tomcat. More precisely stopping
Tomcat, while is starting. I want to be able to check the status of a
running instance of Tomcat, and be able to wait, before sending the
shutdown command (all this in a Java application), otherwise Tomcat
throws an exception, or sends a message stating that catalina engine
has not started yet. So, my question is, does anyone know some class
that exists in tomcat that enables me to check
it's status?
I would appreciate any help.
Best regards,
Miguel Correia Ricardo

-
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: moving the context xml from $CATALINA_BASE/conf/

2006-10-19 Thread Molina, Teresa
Chuck, I can see where the confusion might arise; I'll clarify.

In my original email, I did write "...know how to specify a location for
the default context.xml file outside of $CATALINA_BASE/conf?"

You should read this as "how to specify a location for the file itself
outside of (not anywhere "beneath") the $CATALINA_BASE/conf directory."
I referred to the "default context.xml file" in order to differentiate
between a context.xml file accessible to *all* webapps running on
Tomcat, the default in $CATALINA_BASE/conf itself, as opposed to webapps
of a particular host,
$CATALINA_BASE/conf/[enginename]/[hostname]/context.xml.

I thought my intentions were made clear by the explanation behind why I
was trying to do this, but I do realize that if you were take "outside
of $CATALINA_BASE/conf" literally,
$CATALINA_BASE/conf/[enginename]/[hostname] qualifies.

So, while I do genuinely thank Peter again for both his time and answer,
I hope that the clarification I supplied him, as well as the explanation
behind the clarification supplied here, will make my need clear.

Thanks again,
Teresa

-Original Message-
From: "Caldarale, Charles R" <[EMAIL PROTECTED]>
Sent: Thu, 19 Oct 2006 14:16:49 GMT
To: Tomcat Users List
Subject: RE: moving the context xml from $CATALINA_BASE/conf/

> From: Molina, Teresa [mailto:[EMAIL PROTECTED] 
> Sent: 2006 October 19, Thursday 09:06
> To: Tomcat Users List
> Subject: RE: moving the context xml from $CATALINA_BASE/conf/
> 
> it's the file itself I wish to move from the $CATALINA_BASE
> directory structure to another location.

I think you just changed the question.  What you asked originally:

> > Does anyone know how to specify a location for the default 
> > context.xml file outside of $CATALINA_BASE/conf?

And Peter gave you the answer:

> you can confgure defaults at
> $CATALINA_BASE/conf/Catalina/localhost/context.xml.default

Was your original question misstated?

 - Chuck 

-Original Message-
From: Molina, Teresa 
Sent: Thursday, October 19, 2006 9:06 AM
To: Tomcat Users List
Subject: RE: moving the context xml from $CATALINA_BASE/conf/

Thanks, Peter, but that's not really the question. I have the defaults
configured and working just fine; it's the file itself I wish to move
from the $CATALINA_BASE directory structure to another location.

-Original Message-
From: Peter Rossbach [mailto:[EMAIL PROTECTED]
Sent: Thursday, October 19, 2006 1:27 AM
To: Tomcat Users List
Subject: Re: moving the context xml from $CATALINA_BASE/conf/

Hi,

you can confgure defaults at  $CATALINA_BASE/conf/context.xml or
$CATALINA_BASE/conf/Catalina/localhost/context.xml.default.

Please read http://tomcat.apache.org/tomcat-5.5-doc/config/context.html

Regards
Peter


Am 19.10.2006 um 00:16 schrieb Molina, Teresa:

> Does anyone know how to specify a location for the default context.xml

> file outside of $CATALINA_BASE/conf? I have looked through the Tomcat 
> source code and found a reference to the constant for the default file

> name itself, "conf/context.xml," as well as getters and setters that 
> seem to over-ride this location and name (in 
> ./container/catalina/src/share/org/apache/catalina/startup/
> ContextConfig
> .java and
> ./container/catalina/src/share/org/apache/catalina/core/
> StandardContext.
> java). However, after a (manual) step-through of the code, I cannot 
> find where any Tomcat class is calling setDefaultContextXml. Also, 
> after grepping every file within the source, I can find no reference 
> to the method outside the classes that define it. (Even if the classes

> are called on reflection, some literal would have to contain a string 
> of the set method name itself.)
>
> Because this alternative configuration need does not seem to be 
> common, I cannot find any reference to moving the context xml file 
> anywhere but the code itself. Obviously, any help would be 
> appreciated.
>
> Background Information (Why I want to do this.)
> --
> The gist of the matter is that I am in the process of upgrading our 
> installation of Tomcat from 4.4 to 5.5. In our 4.x implementation, we 
> had configured a default context to define the jdbc connections 
> commonly used by our multiple webapps (we are running more than a 
> dozen webapps under one Tomcat JVM, basically all using the same DB 
> connection resources). Previously, the context element
> (defaultContext) was contained within the server.xml itself, and we 
> were able to place that xml file in multiple paths on our system, 
> using the "-config {path}"
> option when calling startup.sh.
>
> Because we run our webapps in a variety of environments (a development

> environment, QC, stage and prod) -- each with its own database -- with

> Tomcat 4.x, we are currently able to use multiple versions of the 
> server.xml, wherein the values defined for the connection parameter 
> correspond to its environment's database. (Basically, w

RE: problems with unpacking ROOT.war

2006-10-19 Thread Rizalino DeVilleres
Charles,

I followed the recommendations and certainly fixed the issue, however
doing so, I've created another problem:

Here is the current setup that worked and resolved the issue but it
created issues in serving JSP pages.

$CATALINA_BASE/conf/Engine/Host/ROOT.xml:




$CATALINA_BASE/conf/server.xml:

  

No Context path defined in it.

---

If we drop a Hello World JSP script in /path/to/public_html/servlet

(web server has a URL mapping to pass all request that matches servlet
OR .jsp extensions to Tomcat)

http://domain.com/helloworld.jsp -works.
http://domain.com/servlet/helloworld.jsp -doesnt work and generates a
404 error;

The requested resource (/servlet/helloworld.jsp) is not available.

This works if Tomcat is set as follows but it breaks the other setup
above.

server.xml:




and remove $CATALINA_BASE/conf/Engine/Host/ROOT.xml

---

Is there another work around to get them both working? I believe, this
is the same setup we've had on the previous versions of Tomcat, we
simply want to place all the war/JSPs files in the public_html and
servlets as mentioned above.

Thanks,
Rizalino de Villeres


-Original Message-
From: Caldarale, Charles R [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, October 17, 2006 9:59 AM
To: Tomcat Users List
Subject: RE: problems with unpacking ROOT.war

> From: Michael Courcy [mailto:[EMAIL PROTECTED] 
> Subject: Re: problems with unpacking ROOT.war
> 
> Maybe a stupid clue but instead of
> 
> 
> 
> What happen if u try
> 
> 

Neither one is correct.  You must NOT use the path attribute in a
 element unless the  is defined in server.xml.  The
URI path to the app is determined from the name of the .xml file in the
conf/[engine]/[host] directory.

 - 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]


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



Struggling with Class Loader

2006-10-19 Thread Lei Lin
Greetings,

 

Our web application needs to hot deploy some classes and jar files out of
WEB-INF/classes and WEB-INF/lib directory without shutting down the
application and tomcat.  Is there any way that we can let WebappX Class
Loader know there are new classes have been added and load those classes?

 

Thanks for your help

 

Lei



Re: a discrepancy in webapp behavior in two environments

2006-10-19 Thread Jon Wingfield

Mark,

Take a look at the LiveHttpHeaders plug-in for Firefox. It may help you 
debug this on the client side.
Temporarily enabling the RequestDumperValve on the server side will 
enable you to see if cookies are reaching the server.


HTH,

Jon

Aronszajn, Mark wrote:

Thanks for the information. I had checked Firefox in each environment (I think 
I mentioned this) to be sure that cookies were allowed, but I didn't realize 
that a firewall might block cookies.

I really appreciate the help.

Mark


-Original Message-
From: Caldarale, Charles R [mailto:[EMAIL PROTECTED]
Sent: Wed 10/18/2006 5:15 PM
To: Tomcat Users List
Subject: RE: a discrepancy in webapp behavior in two environments
 




-Original Message-
From: Caldarale, Charles R [mailto:[EMAIL PROTECTED]
Sent: Wed 10/18/2006 5:15 PM
To: Tomcat Users List
Subject: RE: a discrepancy in webapp behavior in two environments
 
From: Aronszajn, Mark [mailto:[EMAIL PROTECTED] 
Subject: RE: a discrepancy in webapp behavior in two environments


Could you explain how the configuration of a firewall would have such
effect on whether the original HttpSession object gets retained?


If you're not appending jsessionid ro the URL, you must be using cookies
to allow the server to identify the client.  Some smart (?) firewalls
(or proxy servers) can be configured to drop cookies.  For an example,
see this thread:
http://marc.theaimsgroup.com/?l=tomcat-user&m=107017907404496&w=2

Note that it could be a firewall installed on your Windows box, not just
an external one.

 - 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]








-
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: Configure resourses for host-context

2006-10-19 Thread Caldarale, Charles R
> From: Roland Carlsson [mailto:[EMAIL PROTECTED] 
> Subject: Configure resourses for host-context
> 
> So my question: Is it possible to put Resources  or preferbly 
> ResourseLinks inside the Host-tag of my server.xml.

If you were to move to 5.5, you could do this.  Each host can have its
own default context settings, by specifying them in:
conf/[enginename]/[hostname]/context.xml.default

I haven't found an analogous capability in 5.0, but then I haven't used
that version for quite some time.

 - 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: placing context.xml in META-INF works?

2006-10-19 Thread Michael Hencin
Hello, you are correct on both parts. Thanks for the tip, I will make sure to 
fix that.

Also the method I tried worked just fine. My next test is to see if I can 
create diffrent context with the same war, then edit the resulting context.xml 
files to have diffrent db files. this way I can host several of the same apps 
with diffrent db's on our servers for demo purposes.

Mike


- Original Message 
From: Steffen Heil <[EMAIL PROTECTED]>
To: Tomcat Users List 
Sent: Thursday, October 19, 2006 5:45:37 AM
Subject: RE: placing context.xml in META-INF works?


Hi

> 2)  User places our clean database file in the "recommended 
> location on the server machine. i.e c"\databse\ourfile.gdb"

A off-topic side note on this:

The c and the backslashes suggest you are using windows.
The gdb extension suggest you are using firebird or interbase.

My recommendation: Change the extension to fdb, as gdb is handled specially
by windows system restore and you might end up having clients whose
computers back up a copy the the database to system restore on any webapp
restart...
Se firebird lists for more details.

Regards,
  Steffen

Re: Problem Deploying an Application

2006-10-19 Thread Li

If so, I dont see any problem for your tomcat since some webapp can be
deployed without any problem.

Can you check:
1. there is javax/servlet/http/HttpServletRequest in your servlet jar (under
common), do not place it in your WEB-INF/lib
2. you can write a very simple test page as home page for the webapp you r
going to deploy, see if there is any problem

wish it helps, good luck

On 10/19/06, Marco Aurélio S. Silva <[EMAIL PROTECTED]> wrote:


The both are ok! I have some applications running well and some give
me
this problem



2006/10/19, Li <[EMAIL PROTECTED]>:
>
> It looks like servlet jar can not be found, if your class path setting
is
> ok, make sure the permission is ok
>
>
> On 10/19/06, Marco Aurélio S. Silva <[EMAIL PROTECTED]> wrote:
> >
> > Hi folks,
> >
> > I'm trying to deploy an application on my Tomcat 5.5.9 under a Windows
> > 2003
> > Server with JVM 1.5.0_04, and get the following stack error:
> >
> > 19/Out/2006 11:02:13
org.apache.catalina.core.StandardWrapperValveinvoke
> > SEVERE: Servlet.service() for servlet HTMLManager threw exception
> > java.lang.NoClassDefFoundError: javax/servlet/http/HttpServletRequest
> > at
> >
>
org.apache.commons.fileupload.servlet.ServletRequestContext.getContentType
> > (
> > ServletRequestContext.java:72)
> > at org.apache.commons.fileupload.FileUploadBase.parseRequest(
> > FileUploadBase.java:290)
> > at org.apache.commons.fileupload.FileUploadBase.parseRequest(
> > FileUploadBase.java:268)
> > at org.apache.catalina.manager.HTMLManagerServlet.doPost(
> > HTMLManagerServlet.java:157)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> > at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> > ApplicationFilterChain.java:252)
> > at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> > ApplicationFilterChain.java:173)
> > at org.apache.catalina.core.StandardWrapperValve.invoke(
> > StandardWrapperValve.java:213)
> > at org.apache.catalina.core.StandardContextValve.invoke(
> > StandardContextValve.java:178)
> > at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
> > AuthenticatorBase.java:482)
> > at org.apache.catalina.core.StandardHostValve.invoke(
> > StandardHostValve.java
> > :126)
> > at org.apache.catalina.valves.ErrorReportValve.invoke(
> > ErrorReportValve.java
> > :105)
> > at org.apache.catalina.core.StandardEngineValve.invoke(
> > StandardEngineValve.java:107)
> > at org.apache.catalina.connector.CoyoteAdapter.service(
> CoyoteAdapter.java
> > :148)
> > at org.apache.coyote.http11.Http11Processor.process(
Http11Processor.java
> > :856)
> > at
> >
> >
>
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection
> > (Http11Protocol.java:744)
> > at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(
> > PoolTcpEndpoint.java:527)
> > at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(
> > LeaderFollowerWorkerThread.java:80)
> > at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(
> > ThreadPool.java:684)
> > at java.lang.Thread.run(Unknown Source)
> >
> > I was looking for how to solve it, and find that it seems to be a
> problem
> > on
> > the ClassLoader, and only a new installation of the Tomcat solve it!
Is
> > that
> > true or there is another way to solve it?
> >
> > I checked the servlet-api.jar and it's ok!
> >
> > Thanks,
> >
> > --
> > Marco Aurélio S. Silva
> > [EMAIL PROTECTED]
> >
> >
>
>
> --
> When we invent time, we invent death.
>
>


--
Marco Aurélio S. Silva
[EMAIL PROTECTED]





--
When we invent time, we invent death.


Re: Problem Using Tomcat Connector on Windows 2000 Advanced Server

2006-10-19 Thread Darryl Ong

Thanks for the advice Christopher! Will give it a shot. *crosses fingers*

Regards,
Darryl



Christopher Schultz wrote:

Darryl,

  

After installation, I wanted to test if I
could then view JSP pages, so I just created a temporary folder in
the /webapps/ folder called /testing/ and dumped in helloworld.jsp.



That's not enough: you have to actually create a webapp in order for
Tomcat to deploy it. You need a META-INF/context.xml file (unless you
want to configure your context in server.xml, but my understanding is
that it's better to use context.xml).

You'll also need a WEB-INF/web.xml file.

Take a look at the "example" webapp to see some sample files.

Sorry, but just creating a directory and throwing a JSP file into it
won't cause Tomcat to auto-deploy your "webapp".

-chris

  
Send instant messages to your online friends http://asia.messenger.yahoo.com 


-
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 an Application

2006-10-19 Thread Marco Aurélio S. Silva

The both are ok! I have some applications running well and some give me
this problem



2006/10/19, Li <[EMAIL PROTECTED]>:


It looks like servlet jar can not be found, if your class path setting is
ok, make sure the permission is ok


On 10/19/06, Marco Aurélio S. Silva <[EMAIL PROTECTED]> wrote:
>
> Hi folks,
>
> I'm trying to deploy an application on my Tomcat 5.5.9 under a Windows
> 2003
> Server with JVM 1.5.0_04, and get the following stack error:
>
> 19/Out/2006 11:02:13 org.apache.catalina.core.StandardWrapperValveinvoke
> SEVERE: Servlet.service() for servlet HTMLManager threw exception
> java.lang.NoClassDefFoundError: javax/servlet/http/HttpServletRequest
> at
>
org.apache.commons.fileupload.servlet.ServletRequestContext.getContentType
> (
> ServletRequestContext.java:72)
> at org.apache.commons.fileupload.FileUploadBase.parseRequest(
> FileUploadBase.java:290)
> at org.apache.commons.fileupload.FileUploadBase.parseRequest(
> FileUploadBase.java:268)
> at org.apache.catalina.manager.HTMLManagerServlet.doPost(
> HTMLManagerServlet.java:157)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:252)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:173)
> at org.apache.catalina.core.StandardWrapperValve.invoke(
> StandardWrapperValve.java:213)
> at org.apache.catalina.core.StandardContextValve.invoke(
> StandardContextValve.java:178)
> at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
> AuthenticatorBase.java:482)
> at org.apache.catalina.core.StandardHostValve.invoke(
> StandardHostValve.java
> :126)
> at org.apache.catalina.valves.ErrorReportValve.invoke(
> ErrorReportValve.java
> :105)
> at org.apache.catalina.core.StandardEngineValve.invoke(
> StandardEngineValve.java:107)
> at org.apache.catalina.connector.CoyoteAdapter.service(
CoyoteAdapter.java
> :148)
> at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java
> :856)
> at
>
>
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection
> (Http11Protocol.java:744)
> at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(
> PoolTcpEndpoint.java:527)
> at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(
> LeaderFollowerWorkerThread.java:80)
> at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(
> ThreadPool.java:684)
> at java.lang.Thread.run(Unknown Source)
>
> I was looking for how to solve it, and find that it seems to be a
problem
> on
> the ClassLoader, and only a new installation of the Tomcat solve it! Is
> that
> true or there is another way to solve it?
>
> I checked the servlet-api.jar and it's ok!
>
> Thanks,
>
> --
> Marco Aurélio S. Silva
> [EMAIL PROTECTED]
>
>


--
When we invent time, we invent death.





--
Marco Aurélio S. Silva
[EMAIL PROTECTED]


Re: Problem Deploying an Application

2006-10-19 Thread Li

It looks like servlet jar can not be found, if your class path setting is
ok, make sure the permission is ok


On 10/19/06, Marco Aurélio S. Silva <[EMAIL PROTECTED]> wrote:


Hi folks,

I'm trying to deploy an application on my Tomcat 5.5.9 under a Windows
2003
Server with JVM 1.5.0_04, and get the following stack error:

19/Out/2006 11:02:13 org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet HTMLManager threw exception
java.lang.NoClassDefFoundError: javax/servlet/http/HttpServletRequest
at
org.apache.commons.fileupload.servlet.ServletRequestContext.getContentType
(
ServletRequestContext.java:72)
at org.apache.commons.fileupload.FileUploadBase.parseRequest(
FileUploadBase.java:290)
at org.apache.commons.fileupload.FileUploadBase.parseRequest(
FileUploadBase.java:268)
at org.apache.catalina.manager.HTMLManagerServlet.doPost(
HTMLManagerServlet.java:157)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(
ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(
StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(
StandardContextValve.java:178)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
AuthenticatorBase.java:482)
at org.apache.catalina.core.StandardHostValve.invoke(
StandardHostValve.java
:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(
ErrorReportValve.java
:105)
at org.apache.catalina.core.StandardEngineValve.invoke(
StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java
:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java
:856)
at

org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection
(Http11Protocol.java:744)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(
PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(
LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(
ThreadPool.java:684)
at java.lang.Thread.run(Unknown Source)

I was looking for how to solve it, and find that it seems to be a problem
on
the ClassLoader, and only a new installation of the Tomcat solve it! Is
that
true or there is another way to solve it?

I checked the servlet-api.jar and it's ok!

Thanks,

--
Marco Aurélio S. Silva
[EMAIL PROTECTED]





--
When we invent time, we invent death.


RE: moving the context xml from $CATALINA_BASE/conf/

2006-10-19 Thread Caldarale, Charles R
> From: Molina, Teresa [mailto:[EMAIL PROTECTED] 
> Sent: 2006 October 19, Thursday 09:06
> To: Tomcat Users List
> Subject: RE: moving the context xml from $CATALINA_BASE/conf/
> 
> it's the file itself I wish to move from the $CATALINA_BASE
> directory structure to another location.

I think you just changed the question.  What you asked originally:

> > Does anyone know how to specify a location for the default 
> > context.xml file outside of $CATALINA_BASE/conf?

And Peter gave you the answer:

> you can confgure defaults at
> $CATALINA_BASE/conf/Catalina/localhost/context.xml.default

Was your original question misstated?

 - 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]



Problem Deploying an Application

2006-10-19 Thread Marco Aurélio S. Silva

Hi folks,

I'm trying to deploy an application on my Tomcat 5.5.9 under a Windows 2003
Server with JVM 1.5.0_04, and get the following stack error:

19/Out/2006 11:02:13 org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet HTMLManager threw exception
java.lang.NoClassDefFoundError: javax/servlet/http/HttpServletRequest
at
org.apache.commons.fileupload.servlet.ServletRequestContext.getContentType(
ServletRequestContext.java:72)
at org.apache.commons.fileupload.FileUploadBase.parseRequest(
FileUploadBase.java:290)
at org.apache.commons.fileupload.FileUploadBase.parseRequest(
FileUploadBase.java:268)
at org.apache.catalina.manager.HTMLManagerServlet.doPost(
HTMLManagerServlet.java:157)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(
ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(
StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(
StandardContextValve.java:178)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
AuthenticatorBase.java:482)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:105)
at org.apache.catalina.core.StandardEngineValve.invoke(
StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java
:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java
:856)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection
(Http11Protocol.java:744)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(
PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(
LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(
ThreadPool.java:684)
at java.lang.Thread.run(Unknown Source)

I was looking for how to solve it, and find that it seems to be a problem on
the ClassLoader, and only a new installation of the Tomcat solve it! Is that
true or there is another way to solve it?

I checked the servlet-api.jar and it's ok!

Thanks,

--
Marco Aurélio S. Silva
[EMAIL PROTECTED]


RE: IPTABLES

2006-10-19 Thread Asensio, Rodrigo
I will try this aproach.
Im trying with iptables because find out jsvc a little bit late and run
the make an all this stuff... I just modify the iptables and that's all
( if it worked!)

I will try this and let you know what happened
Thanks for the help guys. 

-Original Message-
From: Parsons Technical Services [mailto:[EMAIL PROTECTED]

Sent: Wednesday, October 18, 2006 10:43 PM
To: Tomcat Users List
Subject: Re: IPTABLES

Rodrigo,

Since it appears that you have not gotten an answer, I will take a stab
at this.
I am running CentOS 4 on one of my boxes and I used this method. I think
you are running into the same issue I did with iptables. Open the
iptables file in /etc/sysconfig. DO NOT edit it here. Just look at it.
You should see a line like:
-A FORWARD -j RH-Firewall-1-INPUT
If you do they are using a named list rather than direct FORWARD lines.
You will need to modify the lines you are entering to reflect the second
part of the line above. In my case it was "RH-Firewall-1-INPUT" but
yours may differ.

You will notice lines that start out:
-A RH-Firewall-1-INPUT -p

Instead of -A FORWARD.

Try to do the rules like this substituting the name you found from
above.

iptables -I RH-Firewall-1-INPUT -p tcp --dport 8443 -j ACCEPT iptables
-I RH-Firewall-1-INPUT -p tcp --dport 8080 -j ACCEPT

And if the redirect statements are not in the file:

iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-ports
8080 iptables -t nat -A PREROUTING -p tcp --dport 443 -j REDIRECT
--to-ports 8443

If you look in the file you may see the statements you added originally.

Rerun the original statements with a -D in place of the -A to remove
them. 
Then do iptables save

Hope this helps.

Incase you are wondering the reason things failed before is that the
last line of the named list is a reject all and your added lines were
never reached.

Doug





- Original Message -
From: "Asensio, Rodrigo" <[EMAIL PROTECTED]>
To: "Tomcat Users List" 
Sent: Wednesday, October 18, 2006 4:27 PM
Subject: IPTABLES


my config
Fedora 5
Tomcat 5517
Java Sun 1508

Im running a tomcat in port 80 without httpd
I want redirect packages from 80 to 8080 because tomcat is running as
tomcat user (cant run as other non root under port 1025) and I tried the
IPTABLES redirection aproach but doesnt work

I tried this but no news...

- A another way is to use Iptables to redirect Port 80 and 443 to user
ports (>1024)

* /sbin/iptables -A FORWARD -p tcp --destination-port 443 -j ACCEPT

* /sbin/iptables -t nat -A PREROUTING -j REDIRECT -p tcp
--destination-port 443 --to-ports 8443

* /sbin/iptables -A FORWARD -p tcp --destination-port 80 -j ACCEPT

* /sbin/iptables -t nat -A PREROUTING -j REDIRECT -p tcp
--destination-port 80 --to-ports 8080

/sbin/iptables-save or /etc/init.d/iptables save

from http://wiki.apache.org/tomcat/HowTo

somebody had the same problem ?

thank you.

Rodrigo


---
Rodrigo Asensio
Fuel Management Services
Gilbarco Veeder Root
phone: +1 336 547 5023
email: [EMAIL PROTECTED]




This message (including any attachments) contains confidential
and/or proprietary information intended only for the addressee.
Any unauthorized disclosure, copying, distribution or reliance on
the contents of this information is strictly prohibited and may
constitute a violation of law.  If you are not the intended
recipient, please notify the sender immediately by responding to
this e-mail, and delete the message from your system.  If you
have any questions about this e-mail please notify the sender
immediately. 



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


This message (including any attachments) contains confidential
and/or proprietary information intended only for the addressee.
Any unauthorized disclosure, copying, distribution or reliance on
the contents of this information is strictly prohibited and may
constitute a violation of law.  If you are not the intended
recipient, please notify the sender immediately by responding to
this e-mail, and delete the message from your system.  If you
have any questions about this e-mail please notify the sender
immediately.

-
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: moving the context xml from $CATALINA_BASE/conf/

2006-10-19 Thread Molina, Teresa
Thanks, Peter, but that's not really the question. I have the defaults
configured and working just fine; it's the file itself I wish to move
from the $CATALINA_BASE directory structure to another location.

-Original Message-
From: Peter Rossbach [mailto:[EMAIL PROTECTED] 
Sent: Thursday, October 19, 2006 1:27 AM
To: Tomcat Users List
Subject: Re: moving the context xml from $CATALINA_BASE/conf/

Hi,

you can confgure defaults at  $CATALINA_BASE/conf/context.xml or
$CATALINA_BASE/conf/Catalina/localhost/context.xml.default.

Please read http://tomcat.apache.org/tomcat-5.5-doc/config/context.html

Regards
Peter


Am 19.10.2006 um 00:16 schrieb Molina, Teresa:

> Does anyone know how to specify a location for the default context.xml

> file outside of $CATALINA_BASE/conf? I have looked through the Tomcat 
> source code and found a reference to the constant for the default file

> name itself, "conf/context.xml," as well as getters and setters that 
> seem to over-ride this location and name (in 
> ./container/catalina/src/share/org/apache/catalina/startup/
> ContextConfig
> .java and
> ./container/catalina/src/share/org/apache/catalina/core/
> StandardContext.
> java). However, after a (manual) step-through of the code, I cannot 
> find where any Tomcat class is calling setDefaultContextXml. Also, 
> after grepping every file within the source, I can find no reference 
> to the method outside the classes that define it. (Even if the classes

> are called on reflection, some literal would have to contain a string 
> of the set method name itself.)
>
> Because this alternative configuration need does not seem to be 
> common, I cannot find any reference to moving the context xml file 
> anywhere but the code itself. Obviously, any help would be 
> appreciated.
>
> Background Information (Why I want to do this.)
> --
> The gist of the matter is that I am in the process of upgrading our 
> installation of Tomcat from 4.4 to 5.5. In our 4.x implementation, we 
> had configured a default context to define the jdbc connections 
> commonly used by our multiple webapps (we are running more than a 
> dozen webapps under one Tomcat JVM, basically all using the same DB 
> connection resources). Previously, the context element 
> (defaultContext) was contained within the server.xml itself, and we 
> were able to place that xml file in multiple paths on our system, 
> using the "-config {path}"
> option when calling startup.sh.
>
> Because we run our webapps in a variety of environments (a development

> environment, QC, stage and prod) -- each with its own database -- with

> Tomcat 4.x, we are currently able to use multiple versions of the 
> server.xml, wherein the values defined for the connection parameter 
> correspond to its environment's database. (Basically, we have defined 
> a conf directory for each of our environments, like, "conf_dev" and 
> "conf_qa" in which we currently store server.xml; using cvs, we have 
> deployed the directory by checking it out as "conf," allowing us to 
> retrieve the server.xml with the relevant URL and password.)
>
> However, I cannot find a similar solution now that context.xml takes 
> the place of the defaultcontext within server xml. Obviously, you are 
> able to define $CATALINA_BASE on startup, which ultimately would allow

> us to have multiple locations for conf/context.xml, but we do not need

> to also keep multiple copies of all the files under conf, logs, work, 
> etc.
>
> Putting the resources in context.xml under $CATALINA_BASE/conf is the 
> only successful way I have been able to retrieve JNDI resources 
> properly.
>
> Thank you sincerely for your help,
> Teresa



-
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: login page behavior and the 2.4 specification

2006-10-19 Thread Christopher Schultz
Jon (and Mike),

> But you need to cater for the people who hit the login page and then go
> to lunch. Happens more frequently than you might think ;)

I recently switched to securityfilter. It's pretty much a drop-in
replacement for Tomcat's authenticator, and does not suffer from the
problem that you can't login unless you've attempted to access a
protected resource.

http://securityfilter.sourceforge.net

-chris




signature.asc
Description: OpenPGP digital signature


RE: Tomcat, Apache and mod_jk configuration

2006-10-19 Thread DE VINZELLES, Guillaume \(ext.\)
Michael and Chris, thanks a lot for your valuable help.
I'm going to try this ASAP.
The "multi instance" Tomcat seems really interesting.
Thanks again!

Regards

Guillaume de Vinzelles
DSI/PFS Neuf Cegetel
Altran Technologies
 
[EMAIL PROTECTED]
 
01 70 18 21 64
-Message d'origine-
De : Christopher Schultz [mailto:[EMAIL PROTECTED] 
Envoyé : jeudi 19 octobre 2006 15:39
À : Tomcat Users List
Objet : Re: Tomcat, Apache and mod_jk configuration

Guillaume,

> In fact, I've already put the jkMount directive in the VirtualHost 
> conf.

[snip]

> And I'd like to have my webapp accessible through 
> http://preprod.skyce.net/ instead of 
> http://preprod.skyce.net/struts-dev-1/.

It looks like what to have more than one webapp as the "root webapp".

My suggestion would be to run each webapp in a different instance of
Tomcat. It's much easier than you think is it to do this. I use Tomcat
4.1.x, but I'm sure the same is possible with very few changes on 5.5.x:

1. Create a directory structure for each webapp (outside of Tomcat's
installation directory) like this:

struts-dev-1/
struts-dev-1/conf
struts-dev-1/conf/server.xml
struts-dev-1/conf/web.xml
struts-dev-1/webapps
struts-dev-1/logs
struts-dev-1/temp

** Make sure to set your port numbers for your shutdown and connector
ports to something unique among your webapps. I usually use 8x85 for the
ajp13 connector port and 8x86 for the shutdown port.

2. Install your webapp to the directory struts-dev-1/webapps/struts-dev-1

3. Configure Tomcat to use "struts-dev-1" as your root webapp (usually
by specifying that the "path" is "" instead of "/struts-dev-1").

4. Start each Tomcat instance like this:

$ export JAVA_HOME=...
$ export CATALINA_HOME=/path/to/full/tomcat/install
$ export CATALINA_BASE=/path/to/struts-dev-1
$ export CATALINA_TMPDIR=/path/th/struts-dev-1/temp
$ /path/to/full/tomcat/install/bin/startup.sh

This setup allows you to have separate root webapps (or any other kind
of setup). You also have the benefit (I choose to see it as a benefit)
of separate JVMs and Tomcat instances. You can take one down without
bothering the others.

Hope that helps,
-chris



-
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 Using Tomcat Connector on Windows 2000 Advanced Server

2006-10-19 Thread Caldarale, Charles R
> From: Christopher Schultz [mailto:[EMAIL PROTECTED] 
> Subject: Re: Problem Using Tomcat Connector on Windows 2000 
> Advanced Server
> 
> > After installation, I wanted to test if I
> > could then view JSP pages, so I just created a temporary folder in
> > the /webapps/ folder called /testing/ and dumped in helloworld.jsp.
> 
> That's not enough: you have to actually create a webapp in order for
> Tomcat to deploy it. You need a META-INF/context.xml file (unless you
> want to configure your context in server.xml, but my understanding is
> that it's better to use context.xml).
> 
> You'll also need a WEB-INF/web.xml file.

Actually, you don't need either, not for simple connection testing.
What the OP was doing will suffice for his purposes - the jsp runs as
part of the default app (ROOT).  (For example, this is exactly how the
reference to admin is handled when the optional admin app is not
installed.)  Real, independent webapps may or may not need a 
element, depending on whether or not the defaults in conf/context.xml
suffice; you can even get away without a WEB-INF if the app is simple
enough (e.g., all static content) and has its docBase specified
explicitly.

 - 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: mod_jk broken pipe

2006-10-19 Thread Rafael . Almeida
Just my 5 cents: I clicked like a crazy user (clicked 5 or 10 times, not 
giving the chance to to page to be loaded, just when I stopped clicking) 
on a link to a jsp in our page and got some broken pipes, and I use 
mod_proxy_ajp, apache 2.2.3, Jdk 1.5.07 and tomcat 5.5.17. Under heavy 
load I suppose we have more broken pipes because of the delay in serving 
pages, so users click and cancel more often.
So broken pipes occur with mod_proxy_ajp too.

Rafael Sarres de Almeida
Seção de Gerenciamento de Rede
Superior Tribunal de Justiça
Tel: (61) 3319-9342





Rainer Jung <[EMAIL PROTECTED]> 
18/10/2006 19:27
Favor responder a
"Tomcat Users List" 


Para
Tomcat Users List 
cc

Assunto
Re: mod_jk broken pipe






Hi Martin,

Martin Kautz schrieb:
> Rainer,
> 
> Thank you, but I'd like to know a bit more. Is there a way to avoid
> "pipes get
> broken"? Even if this issue does not affect the user's expirience I'd
> like to get rid of that log file pollution.
> I forgot to mention that the issue only applies to concurrent
> requests from 'ab'.

Sorry, no. AJP misses a clean way of shutting down a connection.
It's one of the most unpleasant things with mod_jk/Tomcat. I might take
some time and think about a solution, but I'm not very confident, that I
can find an easy one.

I would be interested, if you could confirm, that your ab observation
fits my expectation, i.e. not many more Broken Pipes than concurrency in
ab, even if flag "n" is chosen much higher than "c".

Also: in production the exception should happen for requests with a long
duration in your access log (%D=microseconds in the LogFormat for apache
2.0).

Regards,

Rainer

-
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: Tomcat, Apache and mod_jk configuration

2006-10-19 Thread Christopher Schultz
Guillaume,

> In fact, I've already put the jkMount directive in the VirtualHost 
> conf.

[snip]

> And I'd like to have my webapp accessible through 
> http://preprod.skyce.net/ instead of 
> http://preprod.skyce.net/struts-dev-1/.

It looks like what to have more than one webapp as the "root webapp".

My suggestion would be to run each webapp in a different instance of
Tomcat. It's much easier than you think is it to do this. I use Tomcat
4.1.x, but I'm sure the same is possible with very few changes on 5.5.x:

1. Create a directory structure for each webapp (outside of Tomcat's
installation directory) like this:

struts-dev-1/
struts-dev-1/conf
struts-dev-1/conf/server.xml
struts-dev-1/conf/web.xml
struts-dev-1/webapps
struts-dev-1/logs
struts-dev-1/temp

** Make sure to set your port numbers for your shutdown and connector
ports to something unique among your webapps. I usually use 8x85 for the
ajp13 connector port and 8x86 for the shutdown port.

2. Install your webapp to the directory struts-dev-1/webapps/struts-dev-1

3. Configure Tomcat to use "struts-dev-1" as your root webapp (usually
by specifying that the "path" is "" instead of "/struts-dev-1").

4. Start each Tomcat instance like this:

$ export JAVA_HOME=...
$ export CATALINA_HOME=/path/to/full/tomcat/install
$ export CATALINA_BASE=/path/to/struts-dev-1
$ export CATALINA_TMPDIR=/path/th/struts-dev-1/temp
$ /path/to/full/tomcat/install/bin/startup.sh

This setup allows you to have separate root webapps (or any other kind
of setup). You also have the benefit (I choose to see it as a benefit)
of separate JVMs and Tomcat instances. You can take one down without
bothering the others.

Hope that helps,
-chris




signature.asc
Description: OpenPGP digital signature


Re: Tomcat, Apache and mod_jk configuration

2006-10-19 Thread Michael Courcy

Yes it's what I mean,

in your JkMount declaration change

jkMount /struts-dev-1/*.do ajp13
jkMount /struts-dev-1/*.jsp ajp13

By 


jkMount /*.do ajp13
jkMount /*.jsp ajp13

And your server.xml fragment should look this way



  



It should works.





DE VINZELLES, Guillaume (ext.) a écrit :

In fact, I've already put the jkMount directive in the VirtualHost conf.
It looks like:


DocumentRoot "/var/www/preprod.skyce.net/htdocs"

Options Indexes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all

ServerName preprod.skyce.net
ErrorLog /var/www/preprod.skyce.net/log/error_log
CustomLog /var/www/preprod.skyce.net/log/access_log common
jkMount /struts-dev-1/*.do ajp13
jkMount /struts-dev-1/*.jsp ajp13


And I'd like to have my webapp accessible through http://preprod.skyce.net/ 
instead of http://preprod.skyce.net/struts-dev-1/.

The pertinent fragment of my server.xml is:



My webapps are located in /var/tomcat/webapps, and I got:
CATALINA_BASE: /var/tomcat and CATALINA_HOME: /opt/tomcat5

Thanks !

Guillaume de Vinzelles
DSI/PFS Neuf Cegetel
Altran Technologies
 
[EMAIL PROTECTED]
 
01 70 18 21 64


-Message d'origine-
De : Michael Courcy [mailto:[EMAIL PROTECTED] 
Envoyé : jeudi 19 octobre 2006 14:51

À : Tomcat Users List
Objet : Re: Tomcat, Apache and mod_jk configuration

Hello

Here is a fragment of my server.xml



 verlina.com
 tique-et-puce.fr
 www.tique-et-puce.fr
 shampooing-chien.fr
 www.shampooing-chien.fr



 directory="logs"  prefix="verlina.com_access_log." 
suffix=".txt"

 pattern="common" resolveHosts="false"/>

className="org.apache.catalina.valves.FastCommonAccessLogValve"
 directory="logs"  prefix="verlina.com_access_log." 
suffix=".txt"

 pattern="common" resolveHosts="false"/>


type="javax.sql.DataSource"

 maxActive="100" maxIdle="30" maxWait="1"
  removeAbandoned="true" removeAbandonedTimeout="60" 
logAbandoned="true"

 username="***" password=""
driverClassName="com.mysql.jdbc.Driver"

url="jdbc:mysql://localhost:3306/verlina_com?autoReconnect=true"/>

 

 

And here is a fragment of my httpd.conf


ServerName www.verlina.com
ServerAlias verlina.com
ServerAlias tique-et-puce.fr
ServerAlias www.tique-et-puce.fr
ServerAlias shampooing-chien.fr
ServerAlias www.shampooing-chien.fr

JkMount /* ajp13

ServerAdmin [EMAIL PROTECTED]
#DocumentRoot /home/verlina/www
User verlina
Group users

CustomLog logs/verlina-access_log combined
ScriptAlias /cgi-bin/ /home/verlina/cgi-bin/


The idea is to put the JkMount inside the virtualHost of Apache.

But discussing with Mr Caldarale, this layout is weak, even if it works.

Because if you make any change to the context, you're forced to restart 
tomcat instead of just redeploying your context.


There should be a way for your app to programatticly communicate to 
tomcat  the list of domain the app should handle, but I don't know how 
to do that.


Cheers.




DE VINZELLES, Guillaume (ext.) a écrit :
  

Hi there,

Here is my problem. I got a working Tomcat 5.5.20 handling 4 webapps in 
/var/tomcat/webapps. I got a working Apache 2, configured with several 
virtualhosts.
I managed to connect the Apache to the Tomcat using an AJP13 connector, and 
everything is working fine.
Now, I'd like to map each one of my webapps to a different virtualhost.
For instance, I'd like that my webapp example1, which is in 
/var/tomcat/webapps/example1, should be accessible through www.example1.com 
(and NOT www.example1.com/example1 - I've already that working).
How do you achieve this using the jkMount directives?
I've tried with jkMount /example1/* ajp13 and my webapp is accessible only 
through www.example1.com/example1.

Thanks in advance for your answers!

Guillaume de Vinzelles
DSI/PFS Neuf Cegetel
Altran Technologies
 
[EMAIL PROTECTED]
 
01 70 18 21 64



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


  




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


-
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: Tomcat 5.5.20 library problems

2006-10-19 Thread Christopher Schultz
Alessandro,

> I'm working with 5.5.20 version, on a SuSE linux (both 10 and 10.1).
> I've found library problems in libraries in "common/lib". 

What do you mean, "problems"?

> I've changed these libraries with the ones found on a 5.5.17 version an all 
> work fine...Is that a bug???

Generally, it is not considered a bug when everything works fine ;)
You'll need to be more specific about your problems.

> This is the stack trace:
> 
> org.apache.jasper.JasperException: Validation error messages from 
> TagLibraryValidator for c in /common/templates/publicPage.jspnull: 
> org.xml.sax.SAXParseException: An invalid XML character (Unicode: 0x1b) was 
> found in the CDATA section.Validation error messages from 
> TagLibraryValidator for fmt in /common/templates/publicPage.jspnull: 
> org.xml.sax.SAXParseException: An invalid XML character (Unicode: 0x1b) was 
> found in the CDATA section.

This isn't a library problem: you have bad XML. Depending on your XML
declaration, your XML parser is choking on some character in your XML
document. Look through your document for character 0x1b (that would be
ASCII "ESC", which is often invalid) and fix it.

If you are using a text editor, make sure that you are saving the file
with the same character encoding as the XML declaration suggests.

-chris




signature.asc
Description: OpenPGP digital signature


Re: Problem Using Tomcat Connector on Windows 2000 Advanced Server

2006-10-19 Thread Christopher Schultz
Darryl,

> After installation, I wanted to test if I
> could then view JSP pages, so I just created a temporary folder in
> the /webapps/ folder called /testing/ and dumped in helloworld.jsp.

That's not enough: you have to actually create a webapp in order for
Tomcat to deploy it. You need a META-INF/context.xml file (unless you
want to configure your context in server.xml, but my understanding is
that it's better to use context.xml).

You'll also need a WEB-INF/web.xml file.

Take a look at the "example" webapp to see some sample files.

Sorry, but just creating a directory and throwing a JSP file into it
won't cause Tomcat to auto-deploy your "webapp".

-chris



signature.asc
Description: OpenPGP digital signature


RE: Problem with filter and calling Perl-script with Tomcat 5.5.20

2006-10-19 Thread Gunnar.Bostrom
Hi Mark,

You are absolutly right.

I changed my filter and the CGI.pm as you proposed and it now works for POST 
and GET but NOT with multipart forms.

I've looked into the CGI.pm to see if there was a similar change for multpart 
but I have not found any and my perl knowledge is not good enough.

Any one out there who knows how to do this?

Regards
Gunnar


> -Ursprungligt meddelande-
> Från: Mark Thomas [mailto:[EMAIL PROTECTED] 
> Skickat: den 19 oktober 2006 13:24
> Till: Tomcat Users List
> Ämne: Re: SV: Problem with filter and calling Perl-script 
> with Tomcat 5.5.20
> 
> [EMAIL PROTECTED] wrote:
> > Hi,
> > 
> > That is odd because I have the following problems:
> > 
> > 1) When I post an ordinary form, not a multipart, no 
> parameters will be sent to the Perl script.
> 
> And light dawns. Sorry - should have spotted this sooner. You call
> getParameterMap() in your filter which will drain stdin so 
> there won't be any parameters there for the CGI script to 
> read from the POST.
> 
> A safer bet would be to add your parameter to the end of the 
> URL as part of the query string. I did read 
> http://users.easystreet.com/ovid/cgi_course/lessons/lesson_two.html
> that suggested you would need to tweak your Perl 
> implementation to combine parameters from POST and GET.
> 
> Mark
> 
> -
> To start a new topic, e-mail: users@tomcat.apache.org To 
> unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-
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: login page behavior and the 2.4 specification

2006-10-19 Thread David Smith
IMHO, a custom 408 error page is in order for abandon login pages.  Or 
possibly a meta refresh in the login page that pushes the client back to 
the public page after 10 minutes.


--David


Jon Wingfield wrote:

But you need to cater for the people who hit the login page and then 
go to lunch. Happens more frequently than you might think ;)


David Smith wrote:

Don't send people who logout to a protected page, forcing a login 
page to appear.  Better to offer up a public, non-login page and have 
people click a link to initiate a new request for a protected page.


--David

Michael Swierczek wrote:


I'm receiving a 408 error, and I do understand why.  I just can't
figure out an end-user friendly way to avoid it.

The application runs on Tomcat 5.0.28 with form-based authentication.
It is accessed by some end users from regular PCs, but most connect
from kiosk web browsers.   When someone initially connects, a new
session is generated, they see the login page, they enter their
credentials, and login is fine.   Then they log out, and the login
page sits with no activity for hours, days, or weeks.   The next user
comes along, enters their credentials, and submits.   The request
reaches the server with an expired session id and a 408 error is
generated.

I've read parts of the 2.4 servlet specification, and I realize this
is the expected behavior.  But obviously this isn't what we want, it
is annoying to end users (even if I hide the 408 error and
transparently redirect back to the login page).

I've never used Ajax, but I imagine it would be possible to
transparently retrieve a new session ID from the server as soon as the
user starts to type a username or password.   Assuming I can do that,
it would solve the problem - but I am almost positive other solutions
to this existed before the advent of Ajax.

I would really appreciate any help, or suggestions as to where to
search for more information.

Thanks,
Mike





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




-
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: login page behavior and the 2.4 specification

2006-10-19 Thread Jon Wingfield
But you need to cater for the people who hit the login page and then go 
to lunch. Happens more frequently than you might think ;)


David Smith wrote:
Don't send people who logout to a protected page, forcing a login page 
to appear.  Better to offer up a public, non-login page and have people 
click a link to initiate a new request for a protected page.


--David

Michael Swierczek wrote:


I'm receiving a 408 error, and I do understand why.  I just can't
figure out an end-user friendly way to avoid it.

The application runs on Tomcat 5.0.28 with form-based authentication.
It is accessed by some end users from regular PCs, but most connect
from kiosk web browsers.   When someone initially connects, a new
session is generated, they see the login page, they enter their
credentials, and login is fine.   Then they log out, and the login
page sits with no activity for hours, days, or weeks.   The next user
comes along, enters their credentials, and submits.   The request
reaches the server with an expired session id and a 408 error is
generated.

I've read parts of the 2.4 servlet specification, and I realize this
is the expected behavior.  But obviously this isn't what we want, it
is annoying to end users (even if I hide the 408 error and
transparently redirect back to the login page).

I've never used Ajax, but I imagine it would be possible to
transparently retrieve a new session ID from the server as soon as the
user starts to type a username or password.   Assuming I can do that,
it would solve the problem - but I am almost positive other solutions
to this existed before the advent of Ajax.

I would really appreciate any help, or suggestions as to where to
search for more information.

Thanks,
Mike





-
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: login page behavior and the 2.4 specification

2006-10-19 Thread David Smith
Don't send people who logout to a protected page, forcing a login page 
to appear.  Better to offer up a public, non-login page and have people 
click a link to initiate a new request for a protected page.


--David

Michael Swierczek wrote:


I'm receiving a 408 error, and I do understand why.  I just can't
figure out an end-user friendly way to avoid it.

The application runs on Tomcat 5.0.28 with form-based authentication.
It is accessed by some end users from regular PCs, but most connect
from kiosk web browsers.   When someone initially connects, a new
session is generated, they see the login page, they enter their
credentials, and login is fine.   Then they log out, and the login
page sits with no activity for hours, days, or weeks.   The next user
comes along, enters their credentials, and submits.   The request
reaches the server with an expired session id and a 408 error is
generated.

I've read parts of the 2.4 servlet specification, and I realize this
is the expected behavior.  But obviously this isn't what we want, it
is annoying to end users (even if I hide the 408 error and
transparently redirect back to the login page).

I've never used Ajax, but I imagine it would be possible to
transparently retrieve a new session ID from the server as soon as the
user starts to type a username or password.   Assuming I can do that,
it would solve the problem - but I am almost positive other solutions
to this existed before the advent of Ajax.

I would really appreciate any help, or suggestions as to where to
search for more information.

Thanks,
Mike

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




-
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: login page behavior and the 2.4 specification

2006-10-19 Thread Jon Wingfield
Quick and dirty solution is to have your login page make a meta refresh 
every, say, ten minutes pointing to the index page of your protected 
content.


This simple approach works for us. We also catch "unexpected" errors 
coming back from the login form submission and re-present the login 
page. As you say it's not ideal and better to avoid as many instances as 
possible.


HTH,

Jon

Michael Swierczek wrote:

I'm receiving a 408 error, and I do understand why.  I just can't
figure out an end-user friendly way to avoid it.

The application runs on Tomcat 5.0.28 with form-based authentication.
It is accessed by some end users from regular PCs, but most connect
from kiosk web browsers.   When someone initially connects, a new
session is generated, they see the login page, they enter their
credentials, and login is fine.   Then they log out, and the login
page sits with no activity for hours, days, or weeks.   The next user
comes along, enters their credentials, and submits.   The request
reaches the server with an expired session id and a 408 error is
generated.

I've read parts of the 2.4 servlet specification, and I realize this
is the expected behavior.  But obviously this isn't what we want, it
is annoying to end users (even if I hide the 408 error and
transparently redirect back to the login page).

I've never used Ajax, but I imagine it would be possible to
transparently retrieve a new session ID from the server as soon as the
user starts to type a username or password.   Assuming I can do that,
it would solve the problem - but I am almost positive other solutions
to this existed before the advent of Ajax.

I would really appreciate any help, or suggestions as to where to
search for more information.

Thanks,
Mike

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





-
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: Tomcat, Apache and mod_jk configuration

2006-10-19 Thread DE VINZELLES, Guillaume \(ext.\)
In fact, I've already put the jkMount directive in the VirtualHost conf.
It looks like:


DocumentRoot "/var/www/preprod.skyce.net/htdocs"

Options Indexes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all

ServerName preprod.skyce.net
ErrorLog /var/www/preprod.skyce.net/log/error_log
CustomLog /var/www/preprod.skyce.net/log/access_log common
jkMount /struts-dev-1/*.do ajp13
jkMount /struts-dev-1/*.jsp ajp13


And I'd like to have my webapp accessible through http://preprod.skyce.net/ 
instead of http://preprod.skyce.net/struts-dev-1/.

The pertinent fragment of my server.xml is:



My webapps are located in /var/tomcat/webapps, and I got:
CATALINA_BASE: /var/tomcat and CATALINA_HOME: /opt/tomcat5

Thanks !

Guillaume de Vinzelles
DSI/PFS Neuf Cegetel
Altran Technologies
 
[EMAIL PROTECTED]
 
01 70 18 21 64

-Message d'origine-
De : Michael Courcy [mailto:[EMAIL PROTECTED] 
Envoyé : jeudi 19 octobre 2006 14:51
À : Tomcat Users List
Objet : Re: Tomcat, Apache and mod_jk configuration

Hello

Here is a fragment of my server.xml



 verlina.com
 tique-et-puce.fr
 www.tique-et-puce.fr
 shampooing-chien.fr
 www.shampooing-chien.fr








 

 

And here is a fragment of my httpd.conf


ServerName www.verlina.com
ServerAlias verlina.com
ServerAlias tique-et-puce.fr
ServerAlias www.tique-et-puce.fr
ServerAlias shampooing-chien.fr
ServerAlias www.shampooing-chien.fr

JkMount /* ajp13

ServerAdmin [EMAIL PROTECTED]
#DocumentRoot /home/verlina/www
User verlina
Group users

CustomLog logs/verlina-access_log combined
ScriptAlias /cgi-bin/ /home/verlina/cgi-bin/


The idea is to put the JkMount inside the virtualHost of Apache.

But discussing with Mr Caldarale, this layout is weak, even if it works.

Because if you make any change to the context, you're forced to restart 
tomcat instead of just redeploying your context.

There should be a way for your app to programatticly communicate to 
tomcat  the list of domain the app should handle, but I don't know how 
to do that.

Cheers.




DE VINZELLES, Guillaume (ext.) a écrit :
> Hi there,
>
> Here is my problem. I got a working Tomcat 5.5.20 handling 4 webapps in 
> /var/tomcat/webapps. I got a working Apache 2, configured with several 
> virtualhosts.
> I managed to connect the Apache to the Tomcat using an AJP13 connector, and 
> everything is working fine.
> Now, I'd like to map each one of my webapps to a different virtualhost.
> For instance, I'd like that my webapp example1, which is in 
> /var/tomcat/webapps/example1, should be accessible through www.example1.com 
> (and NOT www.example1.com/example1 - I've already that working).
> How do you achieve this using the jkMount directives?
> I've tried with jkMount /example1/* ajp13 and my webapp is accessible only 
> through www.example1.com/example1.
>
> Thanks in advance for your answers!
>
> Guillaume de Vinzelles
> DSI/PFS Neuf Cegetel
> Altran Technologies
>  
> [EMAIL PROTECTED]
>  
> 01 70 18 21 64
>
>
> -
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>   


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


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



login page behavior and the 2.4 specification

2006-10-19 Thread Michael Swierczek

I'm receiving a 408 error, and I do understand why.  I just can't
figure out an end-user friendly way to avoid it.

The application runs on Tomcat 5.0.28 with form-based authentication.
It is accessed by some end users from regular PCs, but most connect
from kiosk web browsers.   When someone initially connects, a new
session is generated, they see the login page, they enter their
credentials, and login is fine.   Then they log out, and the login
page sits with no activity for hours, days, or weeks.   The next user
comes along, enters their credentials, and submits.   The request
reaches the server with an expired session id and a 408 error is
generated.

I've read parts of the 2.4 servlet specification, and I realize this
is the expected behavior.  But obviously this isn't what we want, it
is annoying to end users (even if I hide the 408 error and
transparently redirect back to the login page).

I've never used Ajax, but I imagine it would be possible to
transparently retrieve a new session ID from the server as soon as the
user starts to type a username or password.   Assuming I can do that,
it would solve the problem - but I am almost positive other solutions
to this existed before the advent of Ajax.

I would really appreciate any help, or suggestions as to where to
search for more information.

Thanks,
Mike

-
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: Tomcat 5.5.20 library problems

2006-10-19 Thread Mark Thomas
Alessandro Ruzzon wrote:
> Hi!
> 
> I'm working with 5.5.20 version, on a SuSE linux (both 10 and 10.1).
> I've found library problems in libraries in "common/lib". 
> I've changed these libraries with the ones found on a 5.5.17 version an all 
> work fine...Is that a bug???

Possibly a side-effect of fixing bug 33407 or the trick it re-uses.

Please open a bug report with the smallest possible JSP that
demonstrates this issue. Mention bug 33407 in the report as well.

Thanks,

Mark


-
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: IIS6.0 with JBoss4.0.3sp1 using mod jk 1.2.19

2006-10-19 Thread Mladen Turk

VikasSharma-ATG, Noida wrote:



Yes, I do have Jakarta connector listed under 'Web Services Extensions'.
But I just have Jakarta connector as Allowed, others are prohibited



OK. Either one will do.


Also you didn't answer if you have defined jakarta
virtual directory under 'Default Web Site' or under
virtial host. It looks you have additional vhost runing
on the port 8081, and you are connecting trough it.


I have Jakarta virtual directory defiend under 'Default Web Site', and I
have TCP port set to 8181 under 'Default Web Site' properties. No other
service on that machine is using port 8181.



Post full configuration (Registry and all config files)
I just retested 1.2.19 on WIN2K3R2 (Windows64/AMD64) with
multiple Web Sites, each having jakarta virtual dir and
ISAPI filter separately defined, and it works fine.

If you .zip the files, not sure they'll be accepted, so
the best would be to put them somewhere on the web, or
CC my email address.

Regards,
Mladen.



-
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: Tomcat, Apache and mod_jk configuration

2006-10-19 Thread Michael Courcy

Hello

Here is a fragment of my server.xml



verlina.com
tique-et-puce.fr
www.tique-et-puce.fr
shampooing-chien.fr
www.shampooing-chien.fr
   


   directory="logs"  prefix="verlina.com_access_log." 
suffix=".txt"

pattern="common" resolveHosts="false"/>

   className="org.apache.catalina.valves.FastCommonAccessLogValve"
directory="logs"  prefix="verlina.com_access_log." 
suffix=".txt"

pattern="common" resolveHosts="false"/>

   
   type="javax.sql.DataSource"

maxActive="100" maxIdle="30" maxWait="1"
 removeAbandoned="true" removeAbandonedTimeout="60" 
logAbandoned="true"

username="***" password=""
   driverClassName="com.mysql.jdbc.Driver"
   
url="jdbc:mysql://localhost:3306/verlina_com?autoReconnect=true"/>





And here is a fragment of my httpd.conf


ServerName www.verlina.com
ServerAlias verlina.com
ServerAlias tique-et-puce.fr
ServerAlias www.tique-et-puce.fr
ServerAlias shampooing-chien.fr
ServerAlias www.shampooing-chien.fr

JkMount /* ajp13

ServerAdmin [EMAIL PROTECTED]
#DocumentRoot /home/verlina/www
User verlina
Group users

CustomLog logs/verlina-access_log combined
ScriptAlias /cgi-bin/ /home/verlina/cgi-bin/


The idea is to put the JkMount inside the virtualHost of Apache.

But discussing with Mr Caldarale, this layout is weak, even if it works.

Because if you make any change to the context, you're forced to restart 
tomcat instead of just redeploying your context.


There should be a way for your app to programatticly communicate to 
tomcat  the list of domain the app should handle, but I don't know how 
to do that.


Cheers.




DE VINZELLES, Guillaume (ext.) a écrit :

Hi there,

Here is my problem. I got a working Tomcat 5.5.20 handling 4 webapps in 
/var/tomcat/webapps. I got a working Apache 2, configured with several 
virtualhosts.
I managed to connect the Apache to the Tomcat using an AJP13 connector, and 
everything is working fine.
Now, I'd like to map each one of my webapps to a different virtualhost.
For instance, I'd like that my webapp example1, which is in 
/var/tomcat/webapps/example1, should be accessible through www.example1.com 
(and NOT www.example1.com/example1 - I've already that working).
How do you achieve this using the jkMount directives?
I've tried with jkMount /example1/* ajp13 and my webapp is accessible only 
through www.example1.com/example1.

Thanks in advance for your answers!

Guillaume de Vinzelles
DSI/PFS Neuf Cegetel
Altran Technologies
 
[EMAIL PROTECTED]
 
01 70 18 21 64



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


  



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



How to setup wildcard host

2006-10-19 Thread Andreas Müller
Hello,

how can I setup a host in server.xml so it will listen on all hosts
"*.sub.domain.tld" ?

I can't find any documentation about the name syntax for a host.

Thanks,
Andreas



-
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: SV: Problem with filter and calling Perl-script with Tomcat 5.5.20

2006-10-19 Thread Mark Thomas
[EMAIL PROTECTED] wrote:
> Hi,
> 
> That is odd because I have the following problems:
> 
> 1) When I post an ordinary form, not a multipart, no parameters will be sent 
> to the Perl script.

And light dawns. Sorry - should have spotted this sooner. You call
getParameterMap() in your filter which will drain stdin so there won't
be any parameters there for the CGI script to read from the POST.

A safer bet would be to add your parameter to the end of the URL as
part of the query string. I did read
http://users.easystreet.com/ovid/cgi_course/lessons/lesson_two.html
that suggested you would need to tweak your Perl implementation to
combine parameters from POST and GET.

Mark

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



Configure resourses for host-context

2006-10-19 Thread Roland Carlsson

Hi!

In my Tomcat 5.0 installation I have a load of Resourses inside the 
GlobalNamingResources. These Resources are linked inside DefaultContext 
with ResourceLinks that I use inside my webapps. This have served me 
well for a quite long time.


Now I face the problem that I basically have to host the same webapps 
for another customer one the same server. So I have to point some of my 
Resources to different databases. I could rename inside my application 
but that doesn't seem like the right way to go. So I figure that instead 
of using the DefaultContext I perhaps could put my ResourceLinks or even 
the Resources itself inside the Host. But so far I have not been able to 
make it work.


So my question: Is it possible to put Resources  or preferbly 
ResourseLinks inside the Host-tag of my server.xml. I'd really like the 
idea of keeping the configuration as GlobalResources and the simply tell 
what each Host have the right to use.


Thank you very much
Roland Carlsson

-
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: placing context.xml in META-INF works?

2006-10-19 Thread Steffen Heil
Hi
 
> 2)  User places our clean database file in the "recommended 
> location on the server machine. i.e c"\databse\ourfile.gdb"

A off-topic side note on this:

The c and the backslashes suggest you are using windows.
The gdb extension suggest you are using firebird or interbase.

My recommendation: Change the extension to fdb, as gdb is handled specially
by windows system restore and you might end up having clients whose
computers back up a copy the the database to system restore on any webapp
restart...
Se firebird lists for more details.

Regards,
  Steffen


smime.p7s
Description: S/MIME cryptographic signature


Tomcat, Apache and mod_jk configuration

2006-10-19 Thread DE VINZELLES, Guillaume \(ext.\)
Hi there,

Here is my problem. I got a working Tomcat 5.5.20 handling 4 webapps in 
/var/tomcat/webapps. I got a working Apache 2, configured with several 
virtualhosts.
I managed to connect the Apache to the Tomcat using an AJP13 connector, and 
everything is working fine.
Now, I'd like to map each one of my webapps to a different virtualhost.
For instance, I'd like that my webapp example1, which is in 
/var/tomcat/webapps/example1, should be accessible through www.example1.com 
(and NOT www.example1.com/example1 - I've already that working).
How do you achieve this using the jkMount directives?
I've tried with jkMount /example1/* ajp13 and my webapp is accessible only 
through www.example1.com/example1.

Thanks in advance for your answers!

Guillaume de Vinzelles
DSI/PFS Neuf Cegetel
Altran Technologies
 
[EMAIL PROTECTED]
 
01 70 18 21 64


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



Tomcat 5.5.20 library problems

2006-10-19 Thread Alessandro Ruzzon
Hi!

I'm working with 5.5.20 version, on a SuSE linux (both 10 and 10.1).
I've found library problems in libraries in "common/lib". 
I've changed these libraries with the ones found on a 5.5.17 version an all 
work fine...Is that a bug???

This is the stack trace:

org.apache.jasper.JasperException: Validation error messages from 
TagLibraryValidator for c in /common/templates/publicPage.jspnull: 
org.xml.sax.SAXParseException: An invalid XML character (Unicode: 0x1b) was 
found in the CDATA section.Validation error messages from 
TagLibraryValidator for fmt in /common/templates/publicPage.jspnull: 
org.xml.sax.SAXParseException: An invalid XML character (Unicode: 0x1b) was 
found in the CDATA section.

org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:50)

org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:407)

org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:72)

org.apache.jasper.compiler.Validator.validateXmlView(Validator.java:1549)
org.apache.jasper.compiler.Validator.validate(Validator.java:1495)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:166)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:295)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)

org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)

org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:305)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1063)

org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:263)

org.apache.struts.tiles.TilesRequestProcessor.processTilesDefinition(TilesRequestProcessor.java:239)

org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(TilesRequestProcessor.java:302)

org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:229)
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1194)
org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414)
javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

it.omitech.cms.hibernate.HibernateFilter.doFilter(HibernateFilter.java:40)

org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:738)

-
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: Downloadable file name is not correct on Linux/Unix box

2006-10-19 Thread Michael Courcy

Did you try to add the mime type in your header ?
Content-Type: application/octet-stream

Mic


Umar Zubair a écrit :

I am using Tomcat5.5. I have a jsp page with option to download xls and pdf
files. When I click the link to download file and try to save it, I can not
see the exact file name. It shows the jsp file name.

By the way, if I run same application on windows box, it works perfect. I am
using following line of code in jsp page.

 


String filename = "summaryReport.xls"




response.setHeader("Content-Disposition", "attachment; filename=" +
fileName);

// Open the output stream

OutputStream outS = response.getOutputStream();

// Transfer bytes from the ZIP file to the output file

byte[] buf = new byte[1024];

int len;

while ((len = in.read(buf)) > 0) {

outS.write(buf, 0, len);

//out.wr

}

outS.close();

 


Instead of showing summaryReport.xls, system shows jsp file name.

Regards,

Umar Zubair

 


NOTE: This communication is intended for the above named person and is
confidential and / or legally privileged. Any opinion(s) expressed in this
communication are not necessarily those of Total Technologies and Solutions
FZ-LLC. If this eMail has come to you in error you must take no action based
upon it, nor must you print it, copy it, forward it, or show it to anyone.
Please delete and destroy this eMail and any attachments and inform the
sender immediately. 


Since the integrity and security of this message cannot be fully guaranteed
on the Internet, we strongly advise that you understand and observe this
lack of security when eMailing us. Total Technologies and Solutions FZ-LLC
is not responsible for the political, religious, racial or partisan opinion
in any correspondence conducted by its domain users. Therefore, any such
opinion expressed, whether explicitly or implicitly implied is not to be
interpreted as that of Total Technologies and Solutions FZ-LLC. 


Although Total Technologies and Solutions FZ-LLC has taken steps to ensure
that all our eMails and attachments are free from any virus, we advise that,
in keeping with best business practices, the recipient must ensure they are
actually virus free. 

 



  



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



SV: Problem with filter and calling Perl-script with Tomcat 5.5.20

2006-10-19 Thread Gunnar.Bostrom
Hi,

That is odd because I have the following problems:

1) When I post an ordinary form, not a multipart, no parameters will be sent to 
the Perl script.

2) When I post a multipart form I get everything OK, but not a parameter that 
my servlet filter introduced.

We have done some changes now to the CGIServlet code so I think it works for 
our case.
I intend to send it to the list when we have done some more testing.

Regards
Gunnar


> -Ursprungligt meddelande-
> Från: Mark Thomas [mailto:[EMAIL PROTECTED] 
> Skickat: den 19 oktober 2006 03:04
> Till: Tomcat Users List
> Ämne: Re: Problem with filter and calling Perl-script with 
> Tomcat 5.5.20
> 
> [EMAIL PROTECTED] wrote:
> > Hi,
> > 
> > We need the fix for multipart forms introduced in 5.5.20 so 
> go back to version 5.5.17 is not an option.
> > 
> > But the problem seems even worse because forms POST'ed does 
> not work with the CGI module! 
> > 
> > We have to many Perl-scripts that use the CGI-module so 
> rewriting them to read directly from stdin is not doable.
> > 
> > The following Perl script taken from a tutorial on the net 
> works if the form is sent with GET but not with POST!
> 
> I have tested the exact code you posted with the latest 5.5.x 
> code (CGI servlet unchanged since 5.5.20) on both Windows and 
> Linux and as expected it works correctly for both GET and POST.
> 
> I am at a loss as to what could be wrong with your system. If 
> I were in your position I would set up remote debugging and 
> start stepping though the code to see exactly what is going on.
> 
> Mark
> 
> -
> To start a new topic, e-mail: users@tomcat.apache.org To 
> unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-
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: placing context.xml in META-INF works?

2006-10-19 Thread Michael Courcy

Caldarale, Charles R a écrit :
From: Michael Courcy [mailto:[EMAIL PROTECTED] 
Subject: Re: placing context.xml in META-INF works?


How do you manage the problem, if you need to define a Host element 
whith many Alias ?



Hosts are a completely different problem, since they are not subordinate
to an app.

  
Can you put the definition of your Host element in  
%TOMCAT_HOME%/conf/[ENGINE]/[HOST]/myApp.xml, and nest the context 
definition inside the host definition ?



No.  Check the doc for the proper hierarchy of elements.

You can programmatically add hosts on the fly - the admin app does it.

 - Chuck
  

Ok thanks.


RE: IIS6.0 with JBoss4.0.3sp1 using mod jk 1.2.19

2006-10-19 Thread VikasSharma-ATG, Noida



Mladen wrote:
> Did you add 'Jakarta Connector' to the list of
> 'Web Services Extensions' in ISS Manager?
> You can simply 'Allow' All Unnknown ISAPI Extensions.

Yes, I do have Jakarta connector listed under 'Web Services Extensions'.
But I just have Jakarta connector as Allowed, others are prohibited

> Also you didn't answer if you have defined jakarta
> virtual directory under 'Default Web Site' or under
> virtial host. It looks you have additional vhost runing
> on the port 8081, and you are connecting trough it.

I have Jakarta virtual directory defiend under 'Default Web Site', and I
have TCP port set to 8181 under 'Default Web Site' properties. No other
service on that machine is using port 8181.

Vikas


DISCLAIMER:
---

The contents of this e-mail and any attachment(s) are confidential and intended 
for the named recipient(s) only. 
It shall not attach any liability on the originator or HCL or its affiliates. 
Any views or opinions presented in 
this email are solely those of the author and may not necessarily reflect the 
opinions of HCL or its affiliates. 
Any form of reproduction, dissemination, copying, disclosure, modification, 
distribution and / or publication of 
this message without the prior written consent of the author of this e-mail is 
strictly prohibited. If you have 
received this email in error please delete it and notify the sender 
immediately. Before opening any mail and 
attachments please check them for viruses and defect.

---

-
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: IIS6.0 with JBoss4.0.3sp1 using mod jk 1.2.19

2006-10-19 Thread Mladen Turk

VikasSharma-ATG, Noida wrote:




Mladen wrote:

extension_uri=/jakarta/isapi_redirect.dll
instead extension_uri=d:\vsharma\jakarta\bin\isapi_redirect.dll


I tried this even, but didn't help. Both the setting generating same
debug log.


Did you add 'Jakarta Connector' to the list of
'Web Services Extensions' in ISS Manager?
You can simply 'Allow' All Unnknown ISAPI Extensions.

Also you didn't answer if you have defined jakarta
virtual directory under 'Default Web Site' or under
virtial host. It looks you have additional vhost runing
on the port 8081, and you are connecting trough it.

Regards,
Mladen.

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