binary streaming / content-type problem with mod_jk ?

2005-07-19 Thread Jérôme Chauvin

Hi all !

I've developed a servlet (BinaryStreaming based on StreamingContent 
by Raj Behera) which does a binary stream of a mpeg video file which is 
created progressively (by another servlet/software/Unix command/... not 
important ) and finally read and played by Quicktime.

I use Apache and Tomcat so I've installed mod_jk

All work well (- MacOS and Windows) but... :
If I go on http://localhost:8080/my_test/BinaryStreaming it 
works well with QuickTime 7 and QuickTime 6 (6, 6.5, 6.5.2, ...).


I have mod_jk so I can go on  
http://localhost/my_test/BinaryStreaming   and here it still works 
well with QT7.
But QT6 seems to wait that the video file is entirely created to start 
the viewing instead of starting to play the movie as soon as there is 
data in it, progressively.
- like it does with QT7 and QT6 with :8080  OR  when I use QT7 without 
:8080.


I think it's due to mod_jk but I've no idea to make it work


I've found that another person had a similar problem, but no answer was 
given :

http://www.junlu.com/msg/107218.html

This message was posted in 09/2004 and it seems that Apache causes 
problems with pre-defined MIME-Types.




Does someone have an answer or an idea ? :-)
I really need to fix this ! :(

Thanks in advance.  :o)

Regards,

Jérôme

---
Jérôme Chauvin

OPSOMAI
77, rue de Charonne
75011 Paris - France
Tél : +33 (0)1 58 39 38 22
Fax : +33 (0)1 43 70 70 72
@ : [EMAIL PROTECTED]
URL : http://www.opsomai.com

AW: Deployment using WAR files

2005-07-19 Thread Bernhard Slominski
Hi Joaquim,

I think you always should do a COMPLETE release of the war file.
So you always have an atomic, conistent relase. 
When it comes to rollback, versioning etc. you're much better off in having
a complete release as war file.
You can use hot deployment, so when you copy the new war file across, it's
automatically deployed and you don't loose your sessions.
However, my experiences with hot deployment are terrible, it was not working
stable at all, I had many application crashes caused by hot deployment. 
So what I do now is build a war file, rename it as zip file and unzip it
manually, they reload the application, it's somehow stuid, but working
stable.

Cheers

Bernhard

 -Ursprüngliche Nachricht-
 Von: Insyde [mailto:[EMAIL PROTECTED]
 Gesendet: Montag, 18. Juli 2005 19:47
 An: Tomcat Users List
 Betreff: Deployment using WAR files
 
 
 Hello,
 
 I have some questions about many people working in the same 
 project and deploying using WAR file.
 
 I belong to a group that is developping a web application and 
 use TOMCAT to test it. At the beginning the deployment was 
 done by copying classes, jsp, and jar files etc to the folder 
 of our web application into webapps subdirectory of TOMCAT. 
 Then we decided to use a WAR file. However there are many 
 people working in the same web application and deployment 
 using a WAR means to undeploy and deploy the whole web 
 application. We thought that one possible solution could be 
 to copy the components of web application  to the folder of 
 web application as we used to do. But is that the correct way 
 to do it ? How to could we deploy part of a web application 
 using war files ? Is it possible to do it ? We wonder how 
 people work in order to solve or minimize this situation. 
 
 Thanks in advance for any help.
 
 Joaquim Roberto.
 

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



Fw: Connection Pool problem...........

2005-07-19 Thread Sridhar



Hi,

How to configure connection pools for Oracle in Tomcat.
follwing code included in the server.xml file even connection pool in not 
configured.copied the Oracle driver into lib directory.

Resource name=XYZDS auth=Container
 type=javax.sql.DataSource 
factory=org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory
 username=kalakaarz password=kalakaarz123
 driverClassName=oracle.jdbc.driver.OracleDriver
 url=jdbc:oracle:thin:@192.168.1.13:1521:smsc
 maxWait=1000 
 removeAbandoned=true
 maxActive=30
 maxIdle=10
 removeAbandonedTimeout=60
 logAbandoned=true/

try{
InitialContext context=new InitialContext();
DataSource ds=(DataSource)context.lookup(XYZDS);
Connection con=ds.getConnection();
--
}catch(Exception e{}


In server name not bound error is coming...

Can anyone help me...

Tomcat vs Jboss-Tomcat

2005-07-19 Thread Sridhar


Hi Everybody,

Is it any difference will come between Tomcat and Jboss-Tomcat.
Which is best for Executing executing only JSPs.


Regards
Sridhar

Connection Pool problem...........

2005-07-19 Thread Sridhar



Hi,

How to configure connection pools for Oracle in Tomcat.
follwing code included in the server.xml file even connection pool in not 
configured.copied the Oracle driver into lib directory.


Resource name=XYZDS auth=Container
type=javax.sql.DataSource 
factory=org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory

username=kalakaarz password=kalakaarz123
driverClassName=oracle.jdbc.driver.OracleDriver
url=jdbc:oracle:thin:@192.168.1.13:1521:smsc
maxWait=1000
removeAbandoned=true
maxActive=30
maxIdle=10
removeAbandonedTimeout=60
logAbandoned=true/

try{
InitialContext context=new InitialContext();
DataSource ds=(DataSource)context.lookup(XYZDS);
Connection con=ds.getConnection();
--
}catch(Exception e{}


In server name not bound error is coming...

Can anyone help me... 



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



Re: Unable to use Python/CGI from Tomcat....

2005-07-19 Thread Tim Diggins
Is it worth writing a quick ksh script to validate your hypothesis that 
the environment (and specifically LD_LIBRARY_PATH) isn't being passed 
through?


additionally (as a crap workaround) you could create a quick script 
which would set the LD_LIBRARY_PATH path and then invoke python, and use 
that in your shebang line...


also, might it not be an idea to a have a specific instance of 
CGIServlet that has executable=python, rather than piping to ksh and 
then to python? (ie why bother with the shebang line, if you don't 
really need it...)


just a few ideas, FWIW...

Tim


Ed Hillmann wrote:

I'm attempting to set up our Tomcat server to run
ViewCVS, which is a Python application.  I've set up
Python on my Solaris 8 box.  I've noticed that to
start python, I need to include a library
(libgdbm.so.3) in my LD_LIBRARY_PATH.  Which I do, and
Python starts up fine.

I've copied the cgi script into the appropriate
directory in my Tomcat server.  CGI is enabled,
because we have other scripts being executed from
within Tomcat.  But whenever I attempt to call the new
Python script, I get the error...

2005-07-19 14:14:32 cgi: runCGI (stderr):ld.so.1:
/ct/ctapp/python241/bin/python: fatal: libgdbm.so.3:
open failed: No such file or directory

Which looks a lot like the error I get if that library
is not in my LD_LIBRARY_PATH.

I've mucked around with startup.sh to displayed that
the processes starting the Tomcat JVM does have this
library in it's environment.  But whatever is
executing the CGI script from within the JVM is not
passing along the environment variables.

The servlet definition in my web.xml looks like...

servlet
servlet-namecgi/servlet-name
   
servlet-classorg.apache.catalina.servlets.CGIServlet/servlet-class

init-param
  param-nameclientInputTimeout/param-name
  param-value100/param-value
/init-param
init-param
  param-namedebug/param-name
  param-value6/param-value
/init-param
init-param
  param-namecgiPathPrefix/param-name
  param-valuecgi-bin/param-value
/init-param
init-param
  param-nameexecutable/param-name
  param-value/usr/bin/ksh/param-value
/init-param
init-param
 
param-namepassShellEnvironment/param-name

  param-valuetrue/param-value
/init-param
load-on-startup5/load-on-startup
/servlet

So, because passShellEnvironment is true, I expected
the shell environment to be passed along to the cgi
script.  It doesn't seem to be.

Am I missing something else?  Surely I can't be the
first one to come up against this?

Thanks for any help,
Ed



 
Do you Yahoo!? 
Messenger 7.0 beta: Free worldwide PC to PC calls

http://au.beta.messenger.yahoo.com

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






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



Re: Session Replication w/ Tomcat 5.0.30

2005-07-19 Thread Peter Rossbach


OK,

a) windows standalone need that mcastBindAddress is set to 127.0.0.1.
b) Please, use for consists sessions handling sticky session at mod:jk, 
backup is only for failover.
c) Used tomcat 5.5.9 with cluster fix pack 
  http://issues.apache.org/bugzilla/show_bug.cgi?id=34389


Peter


Jalenak, Jerry schrieb:


I'm testing a clustered Tomcat (5.0.30) configuration on Windows XP
Professional, behind Apache 2.0.54 with mod_jk as my load balancer.
Load balancing works fine, as I can see sessions being dispatched to
each Tomcat from mod_jk (sticky sessions is disabled.)  The problem I
have is that session replication between the Tomcat instances is
failing.  I've verified that the multicast 'heartbeats' are being sent
(via Ethereal), but I never see any TCP traffic between the instances.
This PC is NOT multi-homed (only have one network card), but I've been
able to do similar setups in Linux (multiple instances on one server)
without any problems.



Does anyone have a suggestions on what I can try to do to get sessions
to replicate?



Thanks!



Jerry Jalenak

Software Engineer

Netopia, Inc.




 






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



Re: Tomcat 5.5 changes in Log format

2005-07-19 Thread Peter Rossbach

read documenctation:
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/logging.html

Robert Abbate schrieb:


Hello. We run a webhosting environment, and in previous releases we were
able to have separate logs for *each* virtual host by using something like
this:

Host name=mydomain.com ...
...
Logger className=org.apache.catalina.logger.FileLogger
prefix=domain.com_log. suffix=.txt directory=/home/melang
timestamp=true/
...
/Host

After we just upgraded to Tomcat 5.5, we see this support was removed, and
are looking for ways to get around this and still provide seperate logging
ability for each virtual host. Does anyone have any suggestions on how to
set something like this up on Tomcat 5.5 ? We looked at log4j but it doesn't
seem like the same thing.

Kind Regards,
Robert


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




 





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



Re: Production cluster crashed with 'SEVERE: TCP Worker thread...' error

2005-07-19 Thread Peter Rossbach

Why you use your own SesssionManager?
Log say that your backup node is down.
Why you don't use the cluster domain feature?
   T1 and T3   Domain 20 at port 10020
   T2 and  T4 Domain 21 at port 10021

   T1 and T2 hosted at host 1
   T3 and T4 hosted at host 2

   Apaches at host 1 and  host 2 can access all tomcats
   A Ip Loadbalancer balanced the load between A1 and A2

Have you install the 5.5.9 ClusterFix pack!!

http://issues.apache.org/bugzilla/show_bug.cgi?id=34389


Peter

Joseph Lam schrieb:


Several minutes before the crash, I found some session replication error.
That seemed to cause all my JK connector threads being hold up and no
responding to further requests.

catalina.out:

Jul 15, 2005 10:29:01 AM org.apache.catalina.cluster.tcp.DataSender
pushMessage
INFO: resending 504 bytes to 203.194.228.76:4001 from 52990
java.net.SocketTimeoutException: Read timed out
   at java.net.SocketInputStream.socketRead0(Native Method)
   at java.net.SocketInputStream.read(SocketInputStream.java:129)
   at java.net.SocketInputStream.read(SocketInputStream.java:182)
   at
org.apache.catalina.cluster.tcp.DataSender.waitForAck(DataSender.java:542)
   at
org.apache.catalina.cluster.tcp.DataSender.pushMessage(DataSender.java:504)
   at
org.apache.catalina.cluster.tcp.DataSender.sendMessage(DataSender.java:378)
   at
org.apache.catalina.cluster.tcp.PooledSocketSender.sendMessage(PooledSocketSender.java:124)
   at
org.apache.catalina.cluster.tcp.ReplicationTransmitter.sendMessageData(ReplicationTransmitter.java:651)
   at
org.apache.catalina.cluster.tcp.ReplicationTransmitter.sendMessage(ReplicationTransmitter.java:348)
   at
org.apache.catalina.cluster.tcp.SimpleTcpCluster.send(SimpleTcpCluster.java:466)
   at
org.apache.catalina.cluster.tcp.SimpleTcpCluster.send(SimpleTcpCluster.java:495)
   at
org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve.java:210)
   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.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:307)
   at
org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:385)
   at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:748)
   at
org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:678)
   at
org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:871)
   at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
   at java.lang.Thread.run(Thread.java:595)
Jul 15, 2005 10:29:01 AM org.apache.catalina.cluster.tcp.DataSender
pushMessage
INFO: resending 487 bytes to 203.194.228.77:4001 from 52737
java.net.SocketException: Socket closed
   at java.net.SocketInputStream.read(SocketInputStream.java:162)
   at java.net.SocketInputStream.read(SocketInputStream.java:182)
   at
org.apache.catalina.cluster.tcp.DataSender.waitForAck(DataSender.java:542)
   at
org.apache.catalina.cluster.tcp.DataSender.pushMessage(DataSender.java:504)
   at
org.apache.catalina.cluster.tcp.DataSender.sendMessage(DataSender.java:378)
   at
org.apache.catalina.cluster.tcp.PooledSocketSender.sendMessage(PooledSocketSender.java:124)
   at
org.apache.catalina.cluster.tcp.ReplicationTransmitter.sendMessageData(ReplicationTransmitter.java:651)
   at
org.apache.catalina.cluster.tcp.ReplicationTransmitter.sendMessage(ReplicationTransmitter.java:348)
   at
org.apache.catalina.cluster.tcp.SimpleTcpCluster.send(SimpleTcpCluster.java:466)
   at
org.apache.catalina.cluster.tcp.SimpleTcpCluster.send(SimpleTcpCluster.java:495)
   at
org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve.java:210)
   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.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:307)
   at
org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:385)
   at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:748)
   at
org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:678)
   at
org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:871)
   at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
   at java.lang.Thread.run(Thread.java:595)
Jul 15, 2005 10:29:02 AM org.apache.catalina.cluster.tcp.DataSender
waitForAck
WARNING: Wasnt able to read acknowledgement from
server[{0}:{1,number,integer}] in {2,number,integer} ms. Disconnecting
socket, and trying again.

Jul 15, 2005 10:29:04 AM

Re: Tomcat vs Jboss-Tomcat

2005-07-19 Thread ohaya
Sridhar,

For just JSPs, you only need Tomcat.  I think that JBoss will be needed
if you use EJBs.

Jim



Sridhar wrote:
 
 Hi Everybody,
 
 Is it any difference will come between Tomcat and Jboss-Tomcat.
 Which is best for Executing executing only JSPs.
 
 Regards
 Sridhar

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



RE: Tomcat vs Jboss-Tomcat

2005-07-19 Thread Raghupathy,Gurumoorthy
For only jsp use tomcat ... More easy to configure and run 

-Original Message-
From: ohaya [mailto:[EMAIL PROTECTED] 
Sent: 19 July 2005 10:57
To: Tomcat Users List
Subject: Re: Tomcat vs Jboss-Tomcat


Sridhar,

For just JSPs, you only need Tomcat.  I think that JBoss will be needed
if you use EJBs.

Jim



Sridhar wrote:
 
 Hi Everybody,
 
 Is it any difference will come between Tomcat and Jboss-Tomcat.
 Which is best for Executing executing only JSPs.
 
 Regards
 Sridhar

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

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



mod_jk: JkUnMount didn't work because of jsessionid

2005-07-19 Thread skausl
Hi,

I want Tomcat to handle dynamic content like JSPs and Apache to deliver
static content like gif files. Therefore my config files for mod_jk include:

  JkMount /test/* worker
  JkUnMount /test/*.gif worker

But if users disable cookies 

  img src=c:url value=/test.gif/

generates URLs like

  /test/test.gif;jsessionid=B66548C5DDF61C8EBBAB9CA86C887A54.worker

and Apache can't find the file because of jsessionid.

How does it work?

Regards,
Stefan


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



FilePermission

2005-07-19 Thread Vieri Di Paola
Hello,
If I try executing the following JSP code (taken from
www.hipergate.org):

FileInputStream oFileStream = new
FileInputStream(Gadgets.chomp(Environment.getEnvVar(KNOWGATE_PROFILES),java.io.File.seperator)+hipergate.cnf);
oProfile.load(oFileStream);

I get this error page:

HTTP Status 500 - 

type Exception report

message 

description: The server encountered an internal error
() that prevented it from fulfilling this request.

exception 

org.apache.jasper.JasperException: access denied
(java.io.FilePermission /usr/bin/env execute)
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:207)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:240)
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:187)
at
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:200)
at
org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:51)
at
org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:129)
at java.security.AccessController.doPrivileged(Native
Method)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:125)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:209)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:144)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2358)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:133)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:118)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:116)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:127)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
at
org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:152)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
at
org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
at java.lang.Thread.run(Thread.java:534)


root cause 

java.security.AccessControlException: access denied
(java.io.FilePermission /usr/bin/env execute)
at
java.security.AccessControlContext.checkPermission(AccessControlContext.java:269)
at
java.security.AccessController.checkPermission(AccessController.java:401)
at
java.lang.SecurityManager.checkPermission(SecurityManager.java:524)
at
java.lang.SecurityManager.checkExec(SecurityManager.java:771)
at java.lang.Runtime.exec(Runtime.java:563)
at java.lang.Runtime.exec(Runtime.java:428)
at java.lang.Runtime.exec(Runtime.java:364)
at java.lang.Runtime.exec(Runtime.java:326)
at com.knowgate.misc.Environment.readEnvVars(Unknown
Source)
at com.knowgate.misc.Environment.getEnvVar(Unknown
Source)
at
org.apache.jsp.setup2_jsp._jspService(setup2_jsp.java:100)
at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:92)
at
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at

Re: JAASRealm and Subject

2005-07-19 Thread Rogerio Baldini das Neves
Jim,

First of all, thanks so much for your help.

I have got same conclusions.
Your Subject is inaccessible directly in your web application, using jaas
realm in tomcat .
You must use request.getRemoteUser and request.isUserInRole.
I think that is impossible to access the list of user´s roles.

In another way, you can create a form that implements your logon and calls
your LoginModule, putting Subject in user session.
So, in your application, you can access Subject from this session.

I don´t know you, but I prefer the first choice.
It´s more beautiful.

And refering to Jo´s message, I don´t believe that it works.
Principals can´t be cast to Subject. They are not related.
But I am not 100% sure about that.

Thank you again.
Rogerio

- Original Message - 
From: ohaya [EMAIL PROTECTED]
To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Monday, July 18, 2005 10:14 PM
Subject: Re: JAASRealm and Subject


 Jo,

 Thanks for the hint.

 I think that your comment, along with the section labelled How can I
 access members of a custom Realm or Principal? here:

 http://wiki.apache.org/jakarta-tomcat/HowTo

 might allow the Principal to be allowed.  I can get to
 request.getUserPrincipal().getName(), but I haven't tried the cast
 yet.  If that works, that would at least allow me to get to the
 credentials, etc. that get populated by the LoginModule, if need be.

 I guess the Subject is inaccessible directly though, but I think that's
 suppose to be the same as request.getRemoteUser if the user has been
 authenticated, right?

 Jim



 Jo wrote:
 
  Is casting request.getUserPrincipal() to your custome-made Principal
gonna
  help get what you want ?
 
  Jojada.-
 
  - Original Message -
  From: ohaya [EMAIL PROTECTED]
  To: Tomcat Users List tomcat-user@jakarta.apache.org
  Sent: Tuesday, July 19, 2005 9:46 AM
  Subject: Re: JAASRealm and Subject
 
   Rogerio,
  
   Try taking a look at this page:
  
   http://www.kopz.org/public/documents/tomcat/jaasintomcat.html
  
   I read through this awhile ago, but as I was just re-reading it for
   maybe the 10th time, I think that I'm starting to see the light and
   understand what the page's author (Michiel Toneman) was trying to say,
   and the problem (with JAAS and Tomcat) that he was trying to describe
   and work around.
  
   In the 1st paragraph, he says:
  
  This is because the principals are used to denote the concepts
  of user and role, and are no longer available in the security
  context in which the webapp is executed. The result of the
  authentication is available only through request.getRemoteUser()
  and request.isUserInRole().
  
   I think that what he is trying to say is that when you use JAAS
   normally with Tomcat (e.g., configure a JAASRealm), the only
artifacts
   from the LoginModule that servlets and JSPs have access to are the
   user (via request.getRemoteUser()) and the user's roles (via calls
to
   request.isUserInRole()).
  
   Putting it another way, I think that the author is saying that your
JSPs
   and servlets under Tomcat simply cannot access things like the
Subject,
   the Principals, etc.
  
   So, this page is about his proposed workaround for this.  From what I
   can tell, the way that he does this is that he has a SecurityFilter,
   which gets invoked BEFORE the LoginModule, and this SecurityFilter
   populates the Subject into the HTTP session before creating the
context
   and invoking the LoginModule.  In other words, this SecurityFilter
kind
   of wedges itself between Tomcat and the LoginModule, I think, and by
   doing that, the Subject, etc. are now no longer lost to being
accessed
   by servlets/JSPs.
  
   If you have a chance, please take a look at the above link, and see if
   you read this page the same way that I do?
  
   Comments from anyone else would be greatly appreciated, as I am very
   curious about this.  It's not so much that I can't seem to access the
   Subject, but it seems like with the Tomcat environment, any work that
   the LoginModule does to populate the Principals, etc. seems to be
   totally inaccessible to servlets and JSPs?
  
   Thanks, and apologies for the longish message...
  
   Jim
  
  
  
   ohaya wrote:
   
Hi,
   
I'm not 100% sure if this is applicable, but I just found this:
   
  Due to a design oversight in the JAAS 1.0,
javax.security.auth.Subject.ge­tSubject() does not return the
Subject
associated with the thread of execution inside a
java.security.AccessController­.doPrivileged() code block. This can
present a inconsistent behavior that is problematic and causes
undesirable effort. com.ibm.websphere.security.aut­h.WSSubject
provides
a work around to associate Subject to thread of execution.
com.ibm.websphere.security.aut­h.WSSubject extends the JAAS
authorization model to J2EE resources.
   
in this thread:
   
   
 

Re: Tomcat vs Jboss-Tomcat

2005-07-19 Thread Sridhar

Hi,

Tomcat is better for the JSPs, But my main problem is my server able to 
handle 2000+ requests per second.So which is better one Web Server or 
Application Server.


Rgds
Sridhar

- Original Message - 
From: Raghupathy,Gurumoorthy [EMAIL PROTECTED]

To: 'Tomcat Users List' tomcat-user@jakarta.apache.org
Sent: Tuesday, July 19, 2005 3:54 PM
Subject: RE: Tomcat vs Jboss-Tomcat



For only jsp use tomcat ... More easy to configure and run

-Original Message-
From: ohaya [mailto:[EMAIL PROTECTED]
Sent: 19 July 2005 10:57
To: Tomcat Users List
Subject: Re: Tomcat vs Jboss-Tomcat


Sridhar,

For just JSPs, you only need Tomcat.  I think that JBoss will be needed
if you use EJBs.

Jim



Sridhar wrote:


Hi Everybody,

Is it any difference will come between Tomcat and Jboss-Tomcat.
Which is best for Executing executing only JSPs.

Regards
Sridhar


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

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






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



RE: Tomcat vs Jboss-Tomcat

2005-07-19 Thread Allistair Crossley
Has anyone pointed out to you that JBoss uses Tomcat for JSP/Servlets? 
Therefore the question is not is Tomcat better, but what management features 
you need and which functionality from the J2EE stack you require.

Allistair.

 -Original Message-
 From: Sridhar [mailto:[EMAIL PROTECTED]
 Sent: 19 July 2005 14:41
 To: Tomcat Users List
 Subject: Re: Tomcat vs Jboss-Tomcat
 
 
 Hi,
 
 Tomcat is better for the JSPs, But my main problem is my 
 server able to 
 handle 2000+ requests per second.So which is better one Web Server or 
 Application Server.
 
 Rgds
 Sridhar
 
 - Original Message - 
 From: Raghupathy,Gurumoorthy 
 [EMAIL PROTECTED]
 To: 'Tomcat Users List' tomcat-user@jakarta.apache.org
 Sent: Tuesday, July 19, 2005 3:54 PM
 Subject: RE: Tomcat vs Jboss-Tomcat
 
 
  For only jsp use tomcat ... More easy to configure and run
 
  -Original Message-
  From: ohaya [mailto:[EMAIL PROTECTED]
  Sent: 19 July 2005 10:57
  To: Tomcat Users List
  Subject: Re: Tomcat vs Jboss-Tomcat
 
 
  Sridhar,
 
  For just JSPs, you only need Tomcat.  I think that JBoss 
 will be needed
  if you use EJBs.
 
  Jim
 
 
 
  Sridhar wrote:
 
  Hi Everybody,
 
  Is it any difference will come between Tomcat and Jboss-Tomcat.
  Which is best for Executing executing only JSPs.
 
  Regards
  Sridhar
 
  
 -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
  
 -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
  
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 


FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE 
---
QAS Ltd.
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---
/FONT


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



JAAS with EJB

2005-07-19 Thread Amleto Di Salle
Hi all,
I am using JAAS with EJB, i.e. inside MyLoginModule i use an EJB in
order to authenticate the user.
When I try to get the Home Interface, I have the ClassCastException in
the PortableRemoteObject.narrow method.

I use Tomcat 5.0.28 and Jboss4.0.2 (EJB container) running in two
separates JVM.



Best Regards
Amleto Di Salle

-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.323 / Virus Database: 267.9.1/51 - Release Date: 18/07/2005
 


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



Re: FilePermission

2005-07-19 Thread Vieri Di Paola
Never mind my question. I solved the problem by adding
a security policy in /etc/tomcat.
Sorry for the newbie question...

--- Vieri Di Paola [EMAIL PROTECTED] wrote:

 Hello,
 If I try executing the following JSP code (taken
 from
 www.hipergate.org):
 
 FileInputStream oFileStream = new

FileInputStream(Gadgets.chomp(Environment.getEnvVar(KNOWGATE_PROFILES),java.io.File.seperator)+hipergate.cnf);
 oProfile.load(oFileStream);
 
 I get this error page:
 
 HTTP Status 500 - 
 
 type Exception report
 
 message 
 
 description: The server encountered an internal
 error
 () that prevented it from fulfilling this request.
 
 exception 
 
 org.apache.jasper.JasperException: access denied
 (java.io.FilePermission /usr/bin/env execute)
   at

org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:207)
   at

org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:240)
   at

org.apache.jasper.servlet.JspServlet.service(JspServlet.java:187)
   at

javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
   at

org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:200)
   at

org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:51)
   at

org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:129)
   at
 java.security.AccessController.doPrivileged(Native
 Method)
   at

org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:125)
   at

org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:209)
   at

org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
   at

org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
   at

org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
   at

org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:144)
   at

org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
   at

org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
   at

org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
   at

org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2358)
   at

org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:133)
   at

org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
   at

org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:118)
   at

org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
   at

org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:116)
   at

org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
   at

org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
   at

org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
   at

org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:127)
   at

org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
   at

org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
   at

org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
   at

org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:152)
   at

org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
   at

org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
   at

org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
   at

org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
   at java.lang.Thread.run(Thread.java:534)
 
 
 root cause 
 
 java.security.AccessControlException: access denied
 (java.io.FilePermission /usr/bin/env execute)
   at

java.security.AccessControlContext.checkPermission(AccessControlContext.java:269)
   at

java.security.AccessController.checkPermission(AccessController.java:401)
   at

java.lang.SecurityManager.checkPermission(SecurityManager.java:524)
   at

java.lang.SecurityManager.checkExec(SecurityManager.java:771)
   at java.lang.Runtime.exec(Runtime.java:563)
   at java.lang.Runtime.exec(Runtime.java:428)
   at java.lang.Runtime.exec(Runtime.java:364)
   at java.lang.Runtime.exec(Runtime.java:326)
   at
 com.knowgate.misc.Environment.readEnvVars(Unknown
 Source)
   at com.knowgate.misc.Environment.getEnvVar(Unknown
 Source)
   at

org.apache.jsp.setup2_jsp._jspService(setup2_jsp.java:100)
   at


SSL Sessions in Tomcat 5.5.4

2005-07-19 Thread Oliver Schoenwald

Hello,

how do I track sessions without using cookies or URL-writing?
Following the Servlet API 2.3, the third way to track sessions is by 
using the SSL-Layer to hold the ID.
I have tried that out with my installation (Apache 2.0.47, mod_jk2, 
Tomcat 5.5.4) and followed the

configuration hints about mod_jk and ssl.
However, using form-based authentication, the server seems not to save 
any session id as an attribute, ssl or anything.
In Bugzilla there was something about using  
request.getAttribute(javax.servlet.request.key_size) which would
activate another attribute which one should get with 
request.getAttribute(javax.servlet.request.ssl_session).

I tried that out - no effect.

Does someone use session tracking under SSL with a similar configuration 
like mine above? How do you set/access

the session id and get hold of the Session (or SSLSession)?

Thank you in advance,

Oliver Schönwald
University of Hagen, Germany


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



Best Way to Share Webapps?

2005-07-19 Thread Pete Lamborne
Hi, I'm just looking for the best way to include/embed single
instances of webapps across various websites.

This includes the ability to wrap the webapps in each website's look and feel.

What solutions have others used or would you use to achieve this?

Thanks, pete.

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



Re: JAASRealm and Subject

2005-07-19 Thread ohaya
Rogerio,

Re. Jo's message:  I didn't interpret his message to mean that you could
access the Subject, but rather, I think that he was suggesting that you
could access the Principal using request.getUserPrincipal(), and then
you could do something like casting the object returned by the
getUserPrincipal() to gain access to the Principal object.

Jim


Rogerio Baldini das Neves wrote:
 
 Jim,
 
 First of all, thanks so much for your help.
 
 I have got same conclusions.
 Your Subject is inaccessible directly in your web application, using jaas
 realm in tomcat .
 You must use request.getRemoteUser and request.isUserInRole.
 I think that is impossible to access the list of user´s roles.
 
 In another way, you can create a form that implements your logon and calls
 your LoginModule, putting Subject in user session.
 So, in your application, you can access Subject from this session.
 
 I don´t know you, but I prefer the first choice.
 It´s more beautiful.
 
 And refering to Jo´s message, I don´t believe that it works.
 Principals can´t be cast to Subject. They are not related.
 But I am not 100% sure about that.
 
 Thank you again.
 Rogerio
 
 - Original Message -
 From: ohaya [EMAIL PROTECTED]
 To: Tomcat Users List tomcat-user@jakarta.apache.org
 Sent: Monday, July 18, 2005 10:14 PM
 Subject: Re: JAASRealm and Subject
 
  Jo,
 
  Thanks for the hint.
 
  I think that your comment, along with the section labelled How can I
  access members of a custom Realm or Principal? here:
 
  http://wiki.apache.org/jakarta-tomcat/HowTo
 
  might allow the Principal to be allowed.  I can get to
  request.getUserPrincipal().getName(), but I haven't tried the cast
  yet.  If that works, that would at least allow me to get to the
  credentials, etc. that get populated by the LoginModule, if need be.
 
  I guess the Subject is inaccessible directly though, but I think that's
  suppose to be the same as request.getRemoteUser if the user has been
  authenticated, right?
 
  Jim
 
 
 
  Jo wrote:
  
   Is casting request.getUserPrincipal() to your custome-made Principal
 gonna
   help get what you want ?
  
   Jojada.-
  
   - Original Message -
   From: ohaya [EMAIL PROTECTED]
   To: Tomcat Users List tomcat-user@jakarta.apache.org
   Sent: Tuesday, July 19, 2005 9:46 AM
   Subject: Re: JAASRealm and Subject
  
Rogerio,
   
Try taking a look at this page:
   
http://www.kopz.org/public/documents/tomcat/jaasintomcat.html
   
I read through this awhile ago, but as I was just re-reading it for
maybe the 10th time, I think that I'm starting to see the light and
understand what the page's author (Michiel Toneman) was trying to say,
and the problem (with JAAS and Tomcat) that he was trying to describe
and work around.
   
In the 1st paragraph, he says:
   
   This is because the principals are used to denote the concepts
   of user and role, and are no longer available in the security
   context in which the webapp is executed. The result of the
   authentication is available only through request.getRemoteUser()
   and request.isUserInRole().
   
I think that what he is trying to say is that when you use JAAS
normally with Tomcat (e.g., configure a JAASRealm), the only
 artifacts
from the LoginModule that servlets and JSPs have access to are the
user (via request.getRemoteUser()) and the user's roles (via calls
 to
request.isUserInRole()).
   
Putting it another way, I think that the author is saying that your
 JSPs
and servlets under Tomcat simply cannot access things like the
 Subject,
the Principals, etc.
   
So, this page is about his proposed workaround for this.  From what I
can tell, the way that he does this is that he has a SecurityFilter,
which gets invoked BEFORE the LoginModule, and this SecurityFilter
populates the Subject into the HTTP session before creating the
 context
and invoking the LoginModule.  In other words, this SecurityFilter
 kind
of wedges itself between Tomcat and the LoginModule, I think, and by
doing that, the Subject, etc. are now no longer lost to being
 accessed
by servlets/JSPs.
   
If you have a chance, please take a look at the above link, and see if
you read this page the same way that I do?
   
Comments from anyone else would be greatly appreciated, as I am very
curious about this.  It's not so much that I can't seem to access the
Subject, but it seems like with the Tomcat environment, any work that
the LoginModule does to populate the Principals, etc. seems to be
totally inaccessible to servlets and JSPs?
   
Thanks, and apologies for the longish message...
   
Jim
   
   
   
ohaya wrote:

 Hi,

 I'm not 100% sure if this is applicable, but I just found this:

   Due to a design oversight in the JAAS 1.0,
 javax.security.auth.Subject.ge­tSubject() does not return the
 Subject
 associated 

Error while deploying a web application in Apache/Tomcat

2005-07-19 Thread Chamarthy, Ravi Kiran \(Exchange\)



Hi,

We have Apache and 
Tomcat installed in Sun OS 5.8. 

When i am trying to 
deploy a new web application in the server , i am getting the following 
error.--2005-07-18 
05:13:43 ContextConfig[/struts-blank] Exception processing JAR at resourcepath 
/WEB-INF/lib/jakarta-oro.jarjavax.servlet.ServletException: Exception 
processing JAR at resource path 
/WEB-INF/lib/jakarta-oro.jar at 
org.apache.catalina.startup.ContextConfig.tldScanJar(ContextConfig.java:930) 
at 
org.apache.catalina.startup.ContextConfig.tldScan(ContextConfig.java:868)...- 
Root Cause -java.io.IOException: No such file or 
directory at 
java.io.UnixFileSystem.createFileExclusively(Native 
Method) at 
java.io.File.checkAndCreate(File.java:1294)...-The 
same application is deployed successfully and working fine in WebLogic8.1. Looks 
to me that is some configuration problem which i am missing.

Made the following 
changes.

1)Created a new 
deployable exploded directory in "/futures/struts-blank". From the same 
exploded directory was able to deploy in WebLogic.2)Added the following 
lines in the Tomcat configuration file 
"server.xml" 
!--Struts-Blank web -- Context 
path="/struts-blank" 
docBase="/futures/struts-blank" 
crossContext="false" 
debug="0" reloadable="true" 
 /Context3)Added the following lines in 
the Apache configuration file "httpsd-local.conf"JkMount /struts-blank/* 
ajp13JkMount /struts-blank/*.jsp ajp13
4)Restarted Apache 
and then Tomcat. 

Please help 
me.Any questions or if you require any additional info please inform 
me.

Thanks,Ravi




**
Please be aware that, notwithstanding the fact that the person sending
this communication has an address in Bear Stearns' e-mail system, this
person is not an employee, agent or representative of Bear Stearns.
Accordingly, this person has no power or authority to represent, make
any recommendation, solicitation, offer or statements or disclose
information on behalf of or in any way bind Bear Stearns or any of its
affiliates.
**


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

Re: JAASRealm and Subject

2005-07-19 Thread Rogerio Baldini das Neves
Ok, Jim

You are right in this point.
It´s possible to get Principal but not Subject.

Rogerio


- Original Message - 
From: ohaya [EMAIL PROTECTED]
To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Tuesday, July 19, 2005 1:10 PM
Subject: Re: JAASRealm and Subject


 Rogerio,

 Re. Jo's message:  I didn't interpret his message to mean that you could
 access the Subject, but rather, I think that he was suggesting that you
 could access the Principal using request.getUserPrincipal(), and then
 you could do something like casting the object returned by the
 getUserPrincipal() to gain access to the Principal object.

 Jim


 Rogerio Baldini das Neves wrote:
 
  Jim,
 
  First of all, thanks so much for your help.
 
  I have got same conclusions.
  Your Subject is inaccessible directly in your web application, using
jaas
  realm in tomcat .
  You must use request.getRemoteUser and request.isUserInRole.
  I think that is impossible to access the list of user´s roles.
 
  In another way, you can create a form that implements your logon and
calls
  your LoginModule, putting Subject in user session.
  So, in your application, you can access Subject from this session.
 
  I don´t know you, but I prefer the first choice.
  It´s more beautiful.
 
  And refering to Jo´s message, I don´t believe that it works.
  Principals can´t be cast to Subject. They are not related.
  But I am not 100% sure about that.
 
  Thank you again.
  Rogerio
 
  - Original Message -
  From: ohaya [EMAIL PROTECTED]
  To: Tomcat Users List tomcat-user@jakarta.apache.org
  Sent: Monday, July 18, 2005 10:14 PM
  Subject: Re: JAASRealm and Subject
 
   Jo,
  
   Thanks for the hint.
  
   I think that your comment, along with the section labelled How can I
   access members of a custom Realm or Principal? here:
  
   http://wiki.apache.org/jakarta-tomcat/HowTo
  
   might allow the Principal to be allowed.  I can get to
   request.getUserPrincipal().getName(), but I haven't tried the cast
   yet.  If that works, that would at least allow me to get to the
   credentials, etc. that get populated by the LoginModule, if need be.
  
   I guess the Subject is inaccessible directly though, but I think
that's
   suppose to be the same as request.getRemoteUser if the user has been
   authenticated, right?
  
   Jim
  
  
  
   Jo wrote:
   
Is casting request.getUserPrincipal() to your custome-made Principal
  gonna
help get what you want ?
   
Jojada.-
   
- Original Message -
From: ohaya [EMAIL PROTECTED]
To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Tuesday, July 19, 2005 9:46 AM
Subject: Re: JAASRealm and Subject
   
 Rogerio,

 Try taking a look at this page:

 http://www.kopz.org/public/documents/tomcat/jaasintomcat.html

 I read through this awhile ago, but as I was just re-reading it
for
 maybe the 10th time, I think that I'm starting to see the light
and
 understand what the page's author (Michiel Toneman) was trying to
say,
 and the problem (with JAAS and Tomcat) that he was trying to
describe
 and work around.

 In the 1st paragraph, he says:

This is because the principals are used to denote the concepts
of user and role, and are no longer available in the
security
context in which the webapp is executed. The result of the
authentication is available only through
request.getRemoteUser()
and request.isUserInRole().

 I think that what he is trying to say is that when you use JAAS
 normally with Tomcat (e.g., configure a JAASRealm), the only
  artifacts
 from the LoginModule that servlets and JSPs have access to are the
 user (via request.getRemoteUser()) and the user's roles (via
calls
  to
 request.isUserInRole()).

 Putting it another way, I think that the author is saying that
your
  JSPs
 and servlets under Tomcat simply cannot access things like the
  Subject,
 the Principals, etc.

 So, this page is about his proposed workaround for this.  From
what I
 can tell, the way that he does this is that he has a
SecurityFilter,
 which gets invoked BEFORE the LoginModule, and this SecurityFilter
 populates the Subject into the HTTP session before creating the
  context
 and invoking the LoginModule.  In other words, this SecurityFilter
  kind
 of wedges itself between Tomcat and the LoginModule, I think, and
by
 doing that, the Subject, etc. are now no longer lost to being
  accessed
 by servlets/JSPs.

 If you have a chance, please take a look at the above link, and
see if
 you read this page the same way that I do?

 Comments from anyone else would be greatly appreciated, as I am
very
 curious about this.  It's not so much that I can't seem to access
the
 Subject, but it seems like with the Tomcat environment, any work
that
 the LoginModule does to populate the 

RE: Apache2/Tomcat55/mod_jk and Sticky Sessions

2005-07-19 Thread Dave Morrow
Thanks. That's actually the document I used as a reference.  I actually
fixed the issue.  The document references an Engine named Standalone
in the server.xml. With tomcat 5.5 I had to change the engine name is
Catalina 


David A. Morrow
Technical Systems Lead
Autodata Solutions Company
[EMAIL PROTECTED]
http://www.autodata.net
Tel: (519) 951-6079
Fax: (519) 451-6615 

 Poor planning on your part does not necessarily constitute an
emergency on my part! 

This message has originated from Autodata Solutions. The attached
material is the Confidential and Proprietary Information of Autodata
Solutions. This email and any files transmitted with it are confidential
and intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please delete
this message and notify the Autodata system administrator at
[EMAIL PROTECTED] mailto:[EMAIL PROTECTED]

-Original Message-
From: Robert F Hall [mailto:[EMAIL PROTECTED] 
Sent: Saturday, July 16, 2005 7:26 PM
To: Tomcat Users List
Subject: Re: Apache2/Tomcat55/mod_jk and Sticky Sessions

Dave,

Try a Google search for: Apache httpd sticky sessions.
One result that looks particularly useful:
http://raibledesigns.com/tomcat/

-Robert

Dave Morrow wrote:

Hi all.  I am attempting to setup a loadbalanced set of Tomcat5.5
servers behind an Apache2 server using mod_jk.  The application
developers have told me that the app will require sticky sessions.  I
have it all configured and working with the exception of the sticky
sessions.  I think my workers.properties is correct so there must be
something I am missing.  For testing, I created a JSP in the ROOT
application of each of the Tomcat servers which simply displays the
server name and SessionID.  The loadbalancing is working, but instead of
maintaining a session, it's flip-flopping between servers and thus
changing session ID's.

My workers.properties contains (note the localhost is in the opposite 
place on the other server);

worker.list= qatomcat1, qatomcat2, loadbalancer #
worker.qatomcat1.port=8009
worker.qatomcat1.host=qahost1
worker.qatomcat1.type=ajp13
worker.qatomcat1.lbfactor=100
worker.qatomcat1.local=0
#
worker.qatomcat2.port=8009
worker.qatomcat2.host=localhost
worker.qatomcat2.type=ajp13
worker.qatomcat2.lbfactor=100
worker.qatomcat2.local=1


David A. Morrow
Technical Systems Lead
Autodata Solutions Company
[EMAIL PROTECTED]
http://www.autodata.net
Tel: (519) 951-6079
Fax: (519) 451-6615

 Poor planning on your part does not necessarily constitute an 
emergency on my part! 

This message has originated from Autodata Solutions. The attached 
material is the Confidential and Proprietary Information of Autodata 
Solutions. This email and any files transmitted with it are 
confidential and intended solely for the use of the individual or 
entity to whom they are addressed. If you have received this email in 
error please delete this message and notify the Autodata system 
administrator at [EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]


  



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


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



tc4 tc4

2005-07-19 Thread Chris Pat
Hi 
I have tc4 working fine.  Installed tc5.5.9 and set
the port to 9080 and of course a diff dir.  However I
cant connect to it at that port even tough I have his
from the tc5 server.xml

!--  Define a non-SSL HTTP/1.1 Connector on port 8080

  -- 
  Connector port=9080 maxHttpHeaderSize=8192
maxThreads=150 minSpareThreads=25
maxSpareThreads=75 enableLookups=false
redirectPort=8443 acceptCount=100
connectionTimeout=2 disableUploadTimeout=true
/ 

Can someone explain what additional config is
necessary to run both tc4  tc5 on 8080 and 9080 on
the same localhost?  tia.

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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



Re: tc4 tc4

2005-07-19 Thread David Smith
Also set the shutdown port at the top of the server.xml to something 
other than 8005 .


--David

Chris Pat wrote:

Hi 
I have tc4 working fine.  Installed tc5.5.9 and set

the port to 9080 and of course a diff dir.  However I
cant connect to it at that port even tough I have his
from the tc5 server.xml

!--  Define a non-SSL HTTP/1.1 Connector on port 8080

 -- 
 Connector port=9080 maxHttpHeaderSize=8192

maxThreads=150 minSpareThreads=25
maxSpareThreads=75 enableLookups=false
redirectPort=8443 acceptCount=100
connectionTimeout=2 disableUploadTimeout=true
/ 


Can someone explain what additional config is
necessary to run both tc4  tc5 on 8080 and 9080 on
the same localhost?  tia.

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


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

 




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



Tomcat5.5: upload deploy is not clearing WAR

2005-07-19 Thread Ned La Celle

We are running
- Apache Tomcat/5.5.7
- JVM=1.5.0_02-b09
- Sun Microsystems Inc. SunOS 5.9 sparc

When our developers try to use the manager application to deploy a war file 
using the Select WAR file to upload and then click the Deploy button.
The application gets deployed but the app.war stays in the tomcat webapp 
directory and is not removed.


If we go in and manually remove the app.war file, then the application stops.

please let me know any suggestions.

- thanks in advance -

- ned -  

Re: tc4 tc4

2005-07-19 Thread Chris Pat
Hi David
Thanks for the response, however I set it to 8006,
checked to make sure nothing in that file of tc4 was
on that port, bounced tc5 and I still cant get in on
that port.  This is the second un/reinstall reboot
today.  Yes, it is a wintel box w2ksrvsp4.  Any ideas?

--- David Smith [EMAIL PROTECTED] wrote:

 Also set the shutdown port at the top of the
 server.xml to something 
 other than 8005 .
 
  --David
 
 Chris Pat wrote:
 
 Hi 
 I have tc4 working fine.  Installed tc5.5.9 and set
 the port to 9080 and of course a diff dir.  However
 I
 cant connect to it at that port even tough I have
 his
 from the tc5 server.xml
 
 !--  Define a non-SSL HTTP/1.1 Connector on port
 8080
 
   -- 
   Connector port=9080 maxHttpHeaderSize=8192
 maxThreads=150 minSpareThreads=25
 maxSpareThreads=75 enableLookups=false
 redirectPort=8443 acceptCount=100
 connectionTimeout=2
 disableUploadTimeout=true
 / 
 
 Can someone explain what additional config is
 necessary to run both tc4  tc5 on 8080 and 9080 on
 the same localhost?  tia.
 
 __
 Do You Yahoo!?
 Tired of spam?  Yahoo! Mail has the best spam
 protection around 
 http://mail.yahoo.com 
 

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

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


__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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



Re: tc4 tc4

2005-07-19 Thread David Smith
Take a look at the log file catalina.out and see if there are any errors 
there. An exception is most likely causing it to fail on startup.


Chris Pat wrote:


Hi David
Thanks for the response, however I set it to 8006,
checked to make sure nothing in that file of tc4 was
on that port, bounced tc5 and I still cant get in on
that port.  This is the second un/reinstall reboot
today.  Yes, it is a wintel box w2ksrvsp4.  Any ideas?

--- David Smith [EMAIL PROTECTED] wrote:

 


Also set the shutdown port at the top of the
server.xml to something 
other than 8005 .


--David

Chris Pat wrote:

   

Hi 
I have tc4 working fine.  Installed tc5.5.9 and set

the port to 9080 and of course a diff dir.  However
 


I
   


cant connect to it at that port even tough I have
 


his

from the tc5 server.xml
   


!--  Define a non-SSL HTTP/1.1 Connector on port
 


8080
   

-- 
Connector port=9080 maxHttpHeaderSize=8192

maxThreads=150 minSpareThreads=25
maxSpareThreads=75 enableLookups=false
redirectPort=8443 acceptCount=100
connectionTimeout=2
 


disableUploadTimeout=true
   

/ 


Can someone explain what additional config is
necessary to run both tc4  tc5 on 8080 and 9080 on
the same localhost?  tia.

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam
 

protection around 
   

http://mail.yahoo.com 

 


-
   


To unsubscribe, e-mail:
 


[EMAIL PROTECTED]
   


For additional commands, e-mail:
 


[EMAIL PROTECTED]
   




 



   


-
 


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


   




__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


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

 




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



Re: tc4 tc4

2005-07-19 Thread Rogerio Baldini das Neves
Hi Chris

Check if there is a enviroment variable called CATALINA_HOME.
It can make things don´t work.

Rogerio


- Original Message - 
From: David Smith [EMAIL PROTECTED]
To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Tuesday, July 19, 2005 4:32 PM
Subject: Re: tc4  tc4


 Take a look at the log file catalina.out and see if there are any errors
 there. An exception is most likely causing it to fail on startup.

 Chris Pat wrote:

 Hi David
 Thanks for the response, however I set it to 8006,
 checked to make sure nothing in that file of tc4 was
 on that port, bounced tc5 and I still cant get in on
 that port.  This is the second un/reinstall reboot
 today.  Yes, it is a wintel box w2ksrvsp4.  Any ideas?
 
 --- David Smith [EMAIL PROTECTED] wrote:
 
 
 
 Also set the shutdown port at the top of the
 server.xml to something
 other than 8005 .
 
  --David
 
 Chris Pat wrote:
 
 
 
 Hi
 I have tc4 working fine.  Installed tc5.5.9 and set
 the port to 9080 and of course a diff dir.  However
 
 
 I
 
 
 cant connect to it at that port even tough I have
 
 
 his
 from the tc5 server.xml
 
 
 !--  Define a non-SSL HTTP/1.1 Connector on port
 
 
 8080
 
 
  --
  Connector port=9080 maxHttpHeaderSize=8192
 maxThreads=150 minSpareThreads=25
 maxSpareThreads=75 enableLookups=false
 redirectPort=8443 acceptCount=100
 connectionTimeout=2
 
 
 disableUploadTimeout=true
 
 
 /
 
 Can someone explain what additional config is
 necessary to run both tc4  tc5 on 8080 and 9080 on
 the same localhost?  tia.
 
 __
 Do You Yahoo!?
 Tired of spam?  Yahoo! Mail has the best spam
 
 
 protection around
 
 
 http://mail.yahoo.com
 
 
 
 -
 
 
 To unsubscribe, e-mail:
 
 
 [EMAIL PROTECTED]
 
 
 For additional commands, e-mail:
 
 
 [EMAIL PROTECTED]
 
 
 
 
 
 
 
 
 
 -
 
 
 To unsubscribe, e-mail:
 [EMAIL PROTECTED]
 For additional commands, e-mail:
 [EMAIL PROTECTED]
 
 
 
 
 
 
 __
 Do You Yahoo!?
 Tired of spam?  Yahoo! Mail has the best spam protection around
 http://mail.yahoo.com
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 


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






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



Re: tc4 tc4

2005-07-19 Thread Chris Pat
Hi Rogerio
Thanks.  But isnt that the same environment var for
TC4 excluding simultaneous instances?

--- Rogerio Baldini das Neves
[EMAIL PROTECTED] wrote:

 Hi Chris
 
 Check if there is a enviroment variable called
 CATALINA_HOME.
 It can make things don´t work.
 
 Rogerio
 
 
 - Original Message - 
 From: David Smith [EMAIL PROTECTED]
 To: Tomcat Users List
 tomcat-user@jakarta.apache.org
 Sent: Tuesday, July 19, 2005 4:32 PM
 Subject: Re: tc4  tc4
 
 
  Take a look at the log file catalina.out and see
 if there are any errors
  there. An exception is most likely causing it to
 fail on startup.
 
  Chris Pat wrote:
 
  Hi David
  Thanks for the response, however I set it to
 8006,
  checked to make sure nothing in that file of tc4
 was
  on that port, bounced tc5 and I still cant get in
 on
  that port.  This is the second un/reinstall
 reboot
  today.  Yes, it is a wintel box w2ksrvsp4.  Any
 ideas?
  
  --- David Smith [EMAIL PROTECTED] wrote:
  
  
  
  Also set the shutdown port at the top of the
  server.xml to something
  other than 8005 .
  
   --David
  
  Chris Pat wrote:
  
  
  
  Hi
  I have tc4 working fine.  Installed tc5.5.9 and
 set
  the port to 9080 and of course a diff dir. 
 However
  
  
  I
  
  
  cant connect to it at that port even tough I
 have
  
  
  his
  from the tc5 server.xml
  
  
  !--  Define a non-SSL HTTP/1.1 Connector on
 port
  
  
  8080
  
  
   --
   Connector port=9080
 maxHttpHeaderSize=8192
  maxThreads=150 minSpareThreads=25
  maxSpareThreads=75 enableLookups=false
  redirectPort=8443 acceptCount=100
  connectionTimeout=2
  
  
  disableUploadTimeout=true
  
  
  /
  
  Can someone explain what additional config is
  necessary to run both tc4  tc5 on 8080 and
 9080 on
  the same localhost?  tia.
  
 

__
  Do You Yahoo!?
  Tired of spam?  Yahoo! Mail has the best spam
  
  
  protection around
  
  
  http://mail.yahoo.com
  
  
  
 

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

-
  
  
  To unsubscribe, e-mail:
  [EMAIL PROTECTED]
  For additional commands, e-mail:
  [EMAIL PROTECTED]
  
  
  
  
  
  
 
 __
  Do You Yahoo!?
  Tired of spam?  Yahoo! Mail has the best spam
 protection around
  http://mail.yahoo.com
  
 

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

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

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





Start your day with Yahoo! - make it your home page 
http://www.yahoo.com/r/hs 
 

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



Re: tc4 tc4

2005-07-19 Thread Chris Pat
Hi David
Thanks.  I sheepishly have to be a, temporary,
subscriber to RTFM.  The log complains that it needs
jdk1.5, of course I knew that but was still thinking
that there was a way to run it on jkd1.4.  Is there? 
Or can I give tc5 the location of the jdk1.5 not as an
environment variable and keep tc4 using the environ as
now is?  I also assume that tc5 on jdk1.4 is for
development only?  Sorry for the newbie barrage.

--- David Smith [EMAIL PROTECTED] wrote:

 Take a look at the log file catalina.out and see if
 there are any errors 
 there. An exception is most likely causing it to
 fail on startup.
 
 Chris Pat wrote:
 
 Hi David
 Thanks for the response, however I set it to 8006,
 checked to make sure nothing in that file of tc4
 was
 on that port, bounced tc5 and I still cant get in
 on
 that port.  This is the second un/reinstall reboot
 today.  Yes, it is a wintel box w2ksrvsp4.  Any
 ideas?
 
 --- David Smith [EMAIL PROTECTED] wrote:
 
   
 
 Also set the shutdown port at the top of the
 server.xml to something 
 other than 8005 .
 
  --David
 
 Chris Pat wrote:
 
 
 
 Hi 
 I have tc4 working fine.  Installed tc5.5.9 and
 set
 the port to 9080 and of course a diff dir. 
 However
   
 
 I
 
 
 cant connect to it at that port even tough I have
   
 
 his
 from the tc5 server.xml
 
 
 !--  Define a non-SSL HTTP/1.1 Connector on port
   
 
 8080
 
 
  -- 
  Connector port=9080 maxHttpHeaderSize=8192
 maxThreads=150 minSpareThreads=25
 maxSpareThreads=75 enableLookups=false
 redirectPort=8443 acceptCount=100
 connectionTimeout=2
   
 
 disableUploadTimeout=true
 
 
 / 
 
 Can someone explain what additional config is
 necessary to run both tc4  tc5 on 8080 and 9080
 on
 the same localhost?  tia.
 

__
 Do You Yahoo!?
 Tired of spam?  Yahoo! Mail has the best spam
   
 
 protection around 
 
 
 http://mail.yahoo.com 
 
   
 

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

-
   
 
 To unsubscribe, e-mail:
 [EMAIL PROTECTED]
 For additional commands, e-mail:
 [EMAIL PROTECTED]
 
 
 
 
 
 
 __
 Do You Yahoo!?
 Tired of spam?  Yahoo! Mail has the best spam
 protection around 
 http://mail.yahoo.com 
 

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

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





Start your day with Yahoo! - make it your home page 
http://www.yahoo.com/r/hs 
 

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



Re: tc4 tc4

2005-07-19 Thread Didier McGillis

Theres a patch you can download for jdk1.4.  jakarta.apache.org



From: Chris Pat [EMAIL PROTECTED]
Reply-To: Tomcat Users List tomcat-user@jakarta.apache.org
To: Tomcat Users List tomcat-user@jakarta.apache.org
Subject: Re: tc4  tc4
Date: Tue, 19 Jul 2005 13:03:35 -0700 (PDT)

Hi David
Thanks.  I sheepishly have to be a, temporary,
subscriber to RTFM.  The log complains that it needs
jdk1.5, of course I knew that but was still thinking
that there was a way to run it on jkd1.4.  Is there?
Or can I give tc5 the location of the jdk1.5 not as an
environment variable and keep tc4 using the environ as
now is?  I also assume that tc5 on jdk1.4 is for
development only?  Sorry for the newbie barrage.

--- David Smith [EMAIL PROTECTED] wrote:

 Take a look at the log file catalina.out and see if
 there are any errors
 there. An exception is most likely causing it to
 fail on startup.

 Chris Pat wrote:

 Hi David
 Thanks for the response, however I set it to 8006,
 checked to make sure nothing in that file of tc4
 was
 on that port, bounced tc5 and I still cant get in
 on
 that port.  This is the second un/reinstall reboot
 today.  Yes, it is a wintel box w2ksrvsp4.  Any
 ideas?
 
 --- David Smith [EMAIL PROTECTED] wrote:
 
 
 
 Also set the shutdown port at the top of the
 server.xml to something
 other than 8005 .
 
  --David
 
 Chris Pat wrote:
 
 
 
 Hi
 I have tc4 working fine.  Installed tc5.5.9 and
 set
 the port to 9080 and of course a diff dir.
 However
 
 
 I
 
 
 cant connect to it at that port even tough I have
 
 
 his
 from the tc5 server.xml
 
 
 !--  Define a non-SSL HTTP/1.1 Connector on port
 
 
 8080
 
 
  --
  Connector port=9080 maxHttpHeaderSize=8192
 maxThreads=150 minSpareThreads=25
 maxSpareThreads=75 enableLookups=false
 redirectPort=8443 acceptCount=100
 connectionTimeout=2
 
 
 disableUploadTimeout=true
 
 
 /
 
 Can someone explain what additional config is
 necessary to run both tc4  tc5 on 8080 and 9080
 on
 the same localhost?  tia.
 

__
 Do You Yahoo!?
 Tired of spam?  Yahoo! Mail has the best spam
 
 
 protection around
 
 
 http://mail.yahoo.com
 
 
 

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

-
 
 
 To unsubscribe, e-mail:
 [EMAIL PROTECTED]
 For additional commands, e-mail:
 [EMAIL PROTECTED]
 
 
 
 
 
 
 __
 Do You Yahoo!?
 Tired of spam?  Yahoo! Mail has the best spam
 protection around
 http://mail.yahoo.com
 

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



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







Start your day with Yahoo! - make it your home page
http://www.yahoo.com/r/hs


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





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



RE: tc4 tc4

2005-07-19 Thread Caldarale, Charles R
 From: Chris Pat [mailto:[EMAIL PROTECTED] 
 Subject: Re: tc4  tc4
 
 The log complains that it needs jdk1.5, of course I 
 knew that but was still thinking that there was a 
 way to run it on jkd1.4.  Is there? 

Yes, just download and unzip the compatibility package from the main
Tomcat download page.

 - 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 unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Tomcat5.5: upload deploy is not clearing WAR

2005-07-19 Thread Ned La Celle

We are running
- Apache Tomcat/5.5.7
- JVM=1.5.0_02-b09
- Sun Microsystems Inc. SunOS 5.9 sparc

When our developers try to use the manager application to deploy a war file 
using the Select WAR file to upload and then click the Deploy button.
The application gets deployed but the app.war stays in the tomcat webapp 
directory and is not removed.


If we go in and manually remove the app.war file, then the application stops.

please let me know any suggestions.

- thanks in advance -

- ned -  

Re: tc4 tc4

2005-07-19 Thread Rogerio Baldini das Neves
Hi Chris,

You need to have your tc4 and tc5 running with different enviroment
variables.

To work in this way, you must edit /path/to/tc4/startup.bat and insert in
the beginning:

set CATALINA_HOME=..
set JAVA_HOME=/path/to/java1.4

and /path/to/tc5/startup.bat :

set CATALINA_HOME=..
set JAVA_HOME=/path/to/java1.5

I think it can solve your problem.

- Original Message - 
From: Chris Pat [EMAIL PROTECTED]
To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Tuesday, July 19, 2005 5:00 PM
Subject: Re: tc4  tc4


 Hi Rogerio
 Thanks.  But isnt that the same environment var for
 TC4 excluding simultaneous instances?

 --- Rogerio Baldini das Neves
 [EMAIL PROTECTED] wrote:

  Hi Chris
 
  Check if there is a enviroment variable called
  CATALINA_HOME.
  It can make things don´t work.
 
  Rogerio
 
 
  - Original Message - 
  From: David Smith [EMAIL PROTECTED]
  To: Tomcat Users List
  tomcat-user@jakarta.apache.org
  Sent: Tuesday, July 19, 2005 4:32 PM
  Subject: Re: tc4  tc4
 
 
   Take a look at the log file catalina.out and see
  if there are any errors
   there. An exception is most likely causing it to
  fail on startup.
  
   Chris Pat wrote:
  
   Hi David
   Thanks for the response, however I set it to
  8006,
   checked to make sure nothing in that file of tc4
  was
   on that port, bounced tc5 and I still cant get in
  on
   that port.  This is the second un/reinstall
  reboot
   today.  Yes, it is a wintel box w2ksrvsp4.  Any
  ideas?
   
   --- David Smith [EMAIL PROTECTED] wrote:
   
   
   
   Also set the shutdown port at the top of the
   server.xml to something
   other than 8005 .
   
--David
   
   Chris Pat wrote:
   
   
   
   Hi
   I have tc4 working fine.  Installed tc5.5.9 and
  set
   the port to 9080 and of course a diff dir.
  However
   
   
   I
   
   
   cant connect to it at that port even tough I
  have
   
   
   his
   from the tc5 server.xml
   
   
   !--  Define a non-SSL HTTP/1.1 Connector on
  port
   
   
   8080
   
   
--
Connector port=9080
  maxHttpHeaderSize=8192
   maxThreads=150 minSpareThreads=25
   maxSpareThreads=75 enableLookups=false
   redirectPort=8443 acceptCount=100
   connectionTimeout=2
   
   
   disableUploadTimeout=true
   
   
   /
   
   Can someone explain what additional config is
   necessary to run both tc4  tc5 on 8080 and
  9080 on
   the same localhost?  tia.
   
  
 
 __
   Do You Yahoo!?
   Tired of spam?  Yahoo! Mail has the best spam
   
   
   protection around
   
   
   http://mail.yahoo.com
   
   
   
  
 
 -
   
   
   To unsubscribe, e-mail:
   
   
   [EMAIL PROTECTED]
   
   
   For additional commands, e-mail:
   
   
   [EMAIL PROTECTED]
   
   
   
   
   
   
   
   
   
  
 
 -
   
   
   To unsubscribe, e-mail:
   [EMAIL PROTECTED]
   For additional commands, e-mail:
   [EMAIL PROTECTED]
   
   
   
   
   
   
  
  __
   Do You Yahoo!?
   Tired of spam?  Yahoo! Mail has the best spam
  protection around
   http://mail.yahoo.com
   
  
 
 -
   To unsubscribe, e-mail:
  [EMAIL PROTECTED]
   For additional commands, e-mail:
  [EMAIL PROTECTED]
   
   
   
  
  
  
 
 -
   To unsubscribe, e-mail:
  [EMAIL PROTECTED]
   For additional commands, e-mail:
  [EMAIL PROTECTED]
  
  
  
 
 
 
 
 -
  To unsubscribe, e-mail:
  [EMAIL PROTECTED]
  For additional commands, e-mail:
  [EMAIL PROTECTED]
 
 




 
 Start your day with Yahoo! - make it your home page
 http://www.yahoo.com/r/hs


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






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



Newbie: Does Tomcat 5.5.9 support JSP 2.2/1.1?

2005-07-19 Thread Leonardo Lagos
Hi,

I am new to servlets, and need to install one for some specific application.
This application requests tomcat 3.3.x, but looking at the page
http://jakarta.apache.org/tomcat/index.html, I would like, of course, to
install the latest and greatest.

However, it is NOT clear, whether tc 5.5.x supports the old JSP versions.

In fact, if tomcat were backward compatible, there shoud NOT be other tomcat
versions available for download.

So, that makes me suspect that backward compatibility is not available on
the latest tomcat.

So, I would like someone here to clarify this question, and make my life
easier.

Regards,

Leo


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



RE: Newbie: Does Tomcat 5.5.9 support JSP 2.2/1.1?

2005-07-19 Thread Didier McGillis


Servlet/JSP Spec  2.4/2.0
Tomcat 5.5 uses the Jasper 2 JSP Engine to implement the JavaServer Pages 
2.0 specification.


http://jakarta.apache.org/tomcat/tomcat-5.5-doc/jasper-howto.html


From: Leonardo Lagos [EMAIL PROTECTED]
Reply-To: [EMAIL PROTECTED]
To: tomcat-user@jakarta.apache.org
Subject: Newbie: Does Tomcat 5.5.9 support JSP 2.2/1.1?
Date: Tue, 19 Jul 2005 16:25:56 -0400

Hi,

I am new to servlets, and need to install one for some specific 
application.

This application requests tomcat 3.3.x, but looking at the page
http://jakarta.apache.org/tomcat/index.html, I would like, of course, to
install the latest and greatest.

However, it is NOT clear, whether tc 5.5.x supports the old JSP versions.

In fact, if tomcat were backward compatible, there shoud NOT be other 
tomcat

versions available for download.

So, that makes me suspect that backward compatibility is not available on
the latest tomcat.

So, I would like someone here to clarify this question, and make my life
easier.

Regards,

Leo


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





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



Can't set login ID

2005-07-19 Thread Ryan Champlin
I'm using tomcat 5.5.7.  When I go to configure it though the monitor and try 
to set the login account it doens't seem to save them.  After setting and 
hitting Apply/OK and then re-opening the configuration screen the setting is 
always set back to Local System Account??

Thanks
,Ryan


Re: tc4 tc4

2005-07-19 Thread David Smith
As others have suggested, the compat package will fix you up for running 
w/ jdk 1.4. It's right where you downloaded tomcat 5.5 .


--David

Chris Pat wrote:


Hi David
Thanks.  I sheepishly have to be a, temporary,
subscriber to RTFM.  The log complains that it needs
jdk1.5, of course I knew that but was still thinking
that there was a way to run it on jkd1.4.  Is there? 
Or can I give tc5 the location of the jdk1.5 not as an

environment variable and keep tc4 using the environ as
now is?  I also assume that tc5 on jdk1.4 is for
development only?  Sorry for the newbie barrage.

--- David Smith [EMAIL PROTECTED] wrote:

 


Take a look at the log file catalina.out and see if
there are any errors 
there. An exception is most likely causing it to

fail on startup.

Chris Pat wrote:

   


Hi David
Thanks for the response, however I set it to 8006,
checked to make sure nothing in that file of tc4
 


was
   


on that port, bounced tc5 and I still cant get in
 


on
   


that port.  This is the second un/reinstall reboot
today.  Yes, it is a wintel box w2ksrvsp4.  Any
 


ideas?
   


--- David Smith [EMAIL PROTECTED] wrote:



 


Also set the shutdown port at the top of the
server.xml to something 
other than 8005 .


--David

Chris Pat wrote:

  

   

Hi 
I have tc4 working fine.  Installed tc5.5.9 and
 


set
   

the port to 9080 and of course a diff dir. 
 


However
   



 


I
  

   


cant connect to it at that port even tough I have


 


his

from the tc5 server.xml
  

   


!--  Define a non-SSL HTTP/1.1 Connector on port


 


8080
  

   

-- 
Connector port=9080 maxHttpHeaderSize=8192

maxThreads=150 minSpareThreads=25
maxSpareThreads=75 enableLookups=false
redirectPort=8443 acceptCount=100
connectionTimeout=2


 


disableUploadTimeout=true
  

   

/ 


Can someone explain what additional config is
necessary to run both tc4  tc5 on 8080 and 9080
 


on
   


the same localhost?  tia.

 


__
   


Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam


 

protection around 
  

   

http://mail.yahoo.com 



 


-
 

  

   


To unsubscribe, e-mail:


 


[EMAIL PROTECTED]
  

   


For additional commands, e-mail:


 


[EMAIL PROTECTED]
  

   



 

  

   


-
   




 


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


  

   


__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam
 

protection around 
   

http://mail.yahoo.com 

 


-
   


To unsubscribe, e-mail:
 


[EMAIL PROTECTED]
   


For additional commands, e-mail:
 


[EMAIL PROTECTED]
   




 



   


-
 


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


   







Start your day with Yahoo! - make it your home page 
http://www.yahoo.com/r/hs 



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

 




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



Re: Tomcat vs Jboss-Tomcat

2005-07-19 Thread Gal Robert

I think, this is not realy about Tomcat nor Jboss-tomcat.
You should consider about clustering (run more instances of your web 
server to handle requests simultaneously). You can achieve this quite 
easily with multiple tomcats+some hardware load balancer


Sridhar wrote:

Hi,

Tomcat is better for the JSPs, But my main problem is my server able to 
handle 2000+ requests per second.So which is better one Web Server or 
Application Server.


Rgds
Sridhar

- Original Message - From: Raghupathy,Gurumoorthy 
[EMAIL PROTECTED]

To: 'Tomcat Users List' tomcat-user@jakarta.apache.org
Sent: Tuesday, July 19, 2005 3:54 PM
Subject: RE: Tomcat vs Jboss-Tomcat



For only jsp use tomcat ... More easy to configure and run

-Original Message-
From: ohaya [mailto:[EMAIL PROTECTED]
Sent: 19 July 2005 10:57
To: Tomcat Users List
Subject: Re: Tomcat vs Jboss-Tomcat


Sridhar,

For just JSPs, you only need Tomcat.  I think that JBoss will be needed
if you use EJBs.

Jim



Sridhar wrote:



Hi Everybody,

Is it any difference will come between Tomcat and Jboss-Tomcat.
Which is best for Executing executing only JSPs.

Regards
Sridhar



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

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






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




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



Tomcat Service isn't reading application specific log4j.properties

2005-07-19 Thread Brian Stephens
Sorry if this is an oft-repeated question.  Digging through old archives
of this list and Google haven't turned up anything directly related.  

I'm trying to run Tomcat 5.5.9 as a windows service (installed it using
service.bat), but for some unknown reason, it does not pick up the
log4j.properties files located in my applications WEB-INF\classes
directory.  As far as I can tell, the java options, classpath and
startup class are identical for both.  Is this a limitation/weakness of
the Windows Service or do I have something mis-configured?

Thank You.
Brian

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



RE: Tomcat Service isn't reading application specific log4j.properties

2005-07-19 Thread skausl

I have log4j-1.2.11.jar in Tomcat\common\lib and log4j.properties in
Tomcat\common\classes\.

 -Original Message-
 Sorry if this is an oft-repeated question.  Digging through 
 old archives
 of this list and Google haven't turned up anything directly related.  
 
 I'm trying to run Tomcat 5.5.9 as a windows service 
 (installed it using
 service.bat), but for some unknown reason, it does not pick up the
 log4j.properties files located in my applications WEB-INF\classes
 directory.  As far as I can tell, the java options, classpath and
 startup class are identical for both.  Is this a 
 limitation/weakness of
 the Windows Service or do I have something mis-configured?
 
 Thank You.
 Brian


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



Re: mod_jk - multiple workers for same Tomcat instance?

2005-07-19 Thread David Hay

Any thoughts?


From: David Hay [EMAIL PROTECTED]
Reply-To: Tomcat Users List tomcat-user@jakarta.apache.org
To: tomcat-user@jakarta.apache.org
Subject: Re: mod_jk - multiple workers for same Tomcat instance?
Date: Thu, 14 Jul 2005 15:00:33 -0400

Hi,

We have set up several contexts eg one for client requests and one for 
admin requests, for a set of Tomcat servers, fronted by Apache.


We would like to balance them differently, allowing one machine to take 
most of the admin load.


There doesn't seem to be a lbfactor parameter for a loadbalancing worker, 
so our second option is to create a seperate client and admin worker for 
each machine, and set their lbfactors separately.  Unless you can recommend 
a better way?


If we go down this route, could you explain how to set up two connectors in 
the tomcat's server.xml with different jvmRoute values to put in 
workers.properties?


many thanks,

David



From: Mladen Turk [EMAIL PROTECTED]
Reply-To: Tomcat Users List tomcat-user@jakarta.apache.org
To: Tomcat Users List tomcat-user@jakarta.apache.org
Subject: Re: mod_jk - multiple workers for same Tomcat instance?
Date: Thu, 14 Jul 2005 20:49:06 +0200

David Hay wrote:

Hi,

Is it possible to specify multiple workers for the same Tomcat instance?



Yes.
But this will impose additional load to the tomcat doubling the number
of connections from apache to mod_jk for each worker.
For ten workers you may end up with 2500 connections with
250 MaxClients defined in the httpd.conf.

We'd like to balance different contexts with different load factors to 
the same Tomcat (hope that makes sense!).




No. But you may feel free to express the idea that led you to consider
something like that.

Regards,
Mladen.

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





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





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



Connection pool exhausted

2005-07-19 Thread Tony Smith
I am runing tomcat 5.0 + postgresql. I set my
connection pool in server.xml as:

Resource
  name=jdbc/mysource
  type=javax.sql.DataSource
  password=
  driverClassName=org.postgresql.Driver
  maxIdle=100
  maxWait=5000
  validationQuery=select * from test
  username=
  url=jdbc:postgresql://localhost:5432/mydb
  maxActive=100/

I call it from my servlet as:

public Connection getConnection(){
try{
Context initCtx = new InitialContext();
Context envCtx =
(Context)initCtx.lookup(java:comp/env);
DataSource ds =
(DataSource)envCtx.lookup(jdbc/mysource);
DatabaseManager.initDataSource(ds);
return ds.getConnection();
}catch(Exception e){
e.printStackTrace();
}

return null;
}


I use the connection as:

Connection connection = getConnection();

//jdbc

//I did not call connection.close(). Should I?

Then, I can run my web app. But not for long. I got
the following exception after browse a few pages:

org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot
get a connection, pool exhausted


How can I fix it?

Thanks,





--- skausl [EMAIL PROTECTED] wrote:

 
 I have log4j-1.2.11.jar in Tomcat\common\lib and
 log4j.properties in
 Tomcat\common\classes\.
 
  -Original Message-
  Sorry if this is an oft-repeated question. 
 Digging through 
  old archives
  of this list and Google haven't turned up anything
 directly related.  
  
  I'm trying to run Tomcat 5.5.9 as a windows
 service 
  (installed it using
  service.bat), but for some unknown reason, it does
 not pick up the
  log4j.properties files located in my applications
 WEB-INF\classes
  directory.  As far as I can tell, the java
 options, classpath and
  startup class are identical for both.  Is this a 
  limitation/weakness of
  the Windows Service or do I have something
 mis-configured?
  
  Thank You.
  Brian
 
 

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


__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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



Security Manager

2005-07-19 Thread Ralf Schneider
Hi,

I have some problems when turning the security manager of Tomcat 5.5.9 on. 
When I load a JSP that has to be compiled after being changed I get a strange 
exception:

ERROR  [19.07.2005 23:30:45]  (ApplicationDispatcher.java:704) - 
Servlet.service() for servlet jsp threw exception
org.xml.sax.SAXException: Internal Error: 
File /javax/servlet/resources/web-app_2_3.dtd not found
at 
org.apache.jasper.xmlparser.MyEntityResolver.resolveEntity(ParserUtils.java:205)
at org.apache.xerces.util.EntityResolverWrapper.resolveEntity(Unknown 
Source)
at org.apache.xerces.impl.XMLEntityManager.resolveEntity(Unknown Source)
at 
org.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch(Unknown 
Source)
at 
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown 
Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
at 
org.apache.jasper.xmlparser.ParserUtils.parseXMLDocument(ParserUtils.java:95)
at 
org.apache.jasper.compiler.JspConfig.processWebDotXml(JspConfig.java:76)
at org.apache.jasper.compiler.JspConfig.init(JspConfig.java:197)
at 
org.apache.jasper.compiler.JspConfig.findJspProperty(JspConfig.java:249)
at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:103)

These are only the first few lines of the callstack. The whole exception is 
very long.

I also turned debugging on (java.security.debug=access), but there's no 
AccessControlException before the SAXException above.

Any ideas what might be the problem? 

Best regards,
Ralf.

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



Re: Unable to use Python/CGI from Tomcat....

2005-07-19 Thread Ed Hillmann
Well, my first attempt was to get Python built so that
it doesn't need the LD_LIBRARY_PATH set.  I'm still
working on that.

As far as the CGIServlet definition, I was under the
impression that Tomcat only allowed one CGIServlet?  I
got this from the doco...

Tomcat's CGI support is largely compatible with
Apache httpd's, but there are some limitations (e.g.,
only one cgi-bin directory).

Now, have I misinterpreted only one cgi-bin
directory?  Yu can only have one directory, but
multiple servlets configured differently to execute
different files in the single directory?  If I havem
then I'm quite happy to try to set up a servlet for my
Python script which knows it's Python.


--- Tim Diggins [EMAIL PROTECTED] wrote:

 Is it worth writing a quick ksh script to validate
 your hypothesis that 
 the environment (and specifically LD_LIBRARY_PATH)
 isn't being passed 
 through?
 
 additionally (as a crap workaround) you could create
 a quick script 
 which would set the LD_LIBRARY_PATH path and then
 invoke python, and use 
 that in your shebang line...
 
 also, might it not be an idea to a have a specific
 instance of 
 CGIServlet that has executable=python, rather than
 piping to ksh and 
 then to python? (ie why bother with the shebang
 line, if you don't 
 really need it...)
 
 just a few ideas, FWIW...
 
 Tim
 
 
 Ed Hillmann wrote:
  I'm attempting to set up our Tomcat server to run
  ViewCVS, which is a Python application.  I've set
 up
  Python on my Solaris 8 box.  I've noticed that to
  start python, I need to include a library
  (libgdbm.so.3) in my LD_LIBRARY_PATH.  Which I do,
 and
  Python starts up fine.
  
  I've copied the cgi script into the appropriate
  directory in my Tomcat server.  CGI is enabled,
  because we have other scripts being executed from
  within Tomcat.  But whenever I attempt to call the
 new
  Python script, I get the error...
  
  2005-07-19 14:14:32 cgi: runCGI (stderr):ld.so.1:
  /ct/ctapp/python241/bin/python: fatal:
 libgdbm.so.3:
  open failed: No such file or directory
  
  Which looks a lot like the error I get if that
 library
  is not in my LD_LIBRARY_PATH.
  
  I've mucked around with startup.sh to displayed
 that
  the processes starting the Tomcat JVM does have
 this
  library in it's environment.  But whatever is
  executing the CGI script from within the JVM is
 not
  passing along the environment variables.
  
  The servlet definition in my web.xml looks like...
  
  servlet
  servlet-namecgi/servlet-name
 
 

servlet-classorg.apache.catalina.servlets.CGIServlet/servlet-class
  init-param
   
 param-nameclientInputTimeout/param-name
param-value100/param-value
  /init-param
  init-param
param-namedebug/param-name
param-value6/param-value
  /init-param
  init-param
param-namecgiPathPrefix/param-name
param-valuecgi-bin/param-value
  /init-param
  init-param
param-nameexecutable/param-name
param-value/usr/bin/ksh/param-value
  /init-param
  init-param
   
  param-namepassShellEnvironment/param-name
param-valuetrue/param-value
  /init-param
  load-on-startup5/load-on-startup
  /servlet
  
  So, because passShellEnvironment is true, I
 expected
  the shell environment to be passed along to the
 cgi
  script.  It doesn't seem to be.
  
  Am I missing something else?  Surely I can't be
 the
  first one to come up against this?
  
  Thanks for any help,
  Ed
  
  
  
 
 
 
  Do you Yahoo!? 
  Messenger 7.0 beta: Free worldwide PC to PC calls
  http://au.beta.messenger.yahoo.com
  
 

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

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


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

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



Tomcat JNDI Realm + Active Directory Server

2005-07-19 Thread Luis Durán
I had a hard time trying to configure Tomcat to authenticate with MS
Active Directory Service, i tried a lot of samples, i edited them but i
didn't get nothing. This is the last configuration i tried:

/META-INF/context-xml:

?xml version=1.0 encoding=UTF-8?

Context path=/moretests
Realm className=org.apache.catalina.realm.JNDIRealm debug=99
connectionURL=ldap://192.168.200.2:389;
referrals=follow
userBase=cn=Users,dc=w2ksvr,dc=local
userSearch=(sAMAccountName={0})
userSubtree=true
userRoleName=memberOf
roleBase=cn=Users,dc=w2ksvr,dc=local
roleSearch=(sAMAccountName={0})
roleSubtree=true
rolename=cn /
/Context

I gave the shot to the bind mode and to the password comparison mode
with any results.

/WEB-INF/web.xml:

?xml version=1.0 encoding=UTF-8?

web-app xmlns=http://java.sun.com/xml/ns/j2ee;
 xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
 xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd;
 version=2.4
login-config
auth-methodBASIC/auth-method
realm-namemoretests/realm-name
/login-config
session-config
session-timeout
30
/session-timeout
/session-config
welcome-file-list
welcome-file
index.jsp
/welcome-file
/welcome-file-list
security-constraint
web-resource-collection
web-resource-namewhole site/web-resource-name
url-pattern/*/url-pattern
http-methodGET/http-method
/web-resource-collection
auth-constraint
role-nameprueba/role-name
/auth-constraint
/security-constraint
security-role
descriptionUsuario/description
role-nameprueba/role-name
/security-role
/web-app

Of course, i have created that group inside ADS and populated it with a
user called elebis with a simple password. I even browsed ADS with ldap
browser and everything seemed ok,

Does anybody know why am I doing wrong? Can anybody help me to work
around it?

Thanks in advanced, pals

-- 

Luis Edgardo Durán Lebis
Soporte Técnico y Sistemas
http://mipagina.cantv.net/elebis
[EMAIL PROTECTED]
0416-7580991


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



What commands to run in the Tomcat Debug Mode on Linux

2005-07-19 Thread Jyothi Palvai
Hi All,
I think I have tomcat running in debug mode on a linux, I did this by running 
the catalina run debug command but I don't know the debug commands to run to 
get to start Tomcat, watch the variables, put debug points etc. Thanks in 
advance for providing this info.
Thanks,
Jyothi


-
 Start your day with Yahoo! - make it your home page 

Re: Connection pool exhausted

2005-07-19 Thread Alon Belman
If you arent closing connections, then exhausting the connection pool
is the expected, eventual result.

Read the document at
http://jakarta.apache.org/tomcat/tomcat-5.0-doc/jndi-datasource-examples-howto.html,
paying special attention to the example of properly written code
[using] a db connection obtained from a connection pool near the
bottom of the page.




On 7/19/05, Tony Smith [EMAIL PROTECTED] wrote:
 I am runing tomcat 5.0 + postgresql. I set my
 connection pool in server.xml as:
 
 Resource
   name=jdbc/mysource
   type=javax.sql.DataSource
   password=
   driverClassName=org.postgresql.Driver
   maxIdle=100
   maxWait=5000
   validationQuery=select * from test
   username=
   url=jdbc:postgresql://localhost:5432/mydb
   maxActive=100/
 
 I call it from my servlet as:
 
 public Connection getConnection(){
 try{
 Context initCtx = new InitialContext();
 Context envCtx =
 (Context)initCtx.lookup(java:comp/env);
 DataSource ds =
 (DataSource)envCtx.lookup(jdbc/mysource);
 DatabaseManager.initDataSource(ds);
 return ds.getConnection();
 }catch(Exception e){
 e.printStackTrace();
 }
 
 return null;
 }
 
 
 I use the connection as:
 
 Connection connection = getConnection();
 
 //jdbc
 
 //I did not call connection.close(). Should I?
 
 Then, I can run my web app. But not for long. I got
 the following exception after browse a few pages:
 
 org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot
 get a connection, pool exhausted
 
 
 How can I fix it?
 
 Thanks,
 
 
 
 
 
 --- skausl [EMAIL PROTECTED] wrote:
 
 
  I have log4j-1.2.11.jar in Tomcat\common\lib and
  log4j.properties in
  Tomcat\common\classes\.
 
   -Original Message-
   Sorry if this is an oft-repeated question.
  Digging through
   old archives
   of this list and Google haven't turned up anything
  directly related.
  
   I'm trying to run Tomcat 5.5.9 as a windows
  service
   (installed it using
   service.bat), but for some unknown reason, it does
  not pick up the
   log4j.properties files located in my applications
  WEB-INF\classes
   directory.  As far as I can tell, the java
  options, classpath and
   startup class are identical for both.  Is this a
   limitation/weakness of
   the Windows Service or do I have something
  mis-configured?
  
   Thank You.
   Brian
 
 
 
 -
  To unsubscribe, e-mail:
  [EMAIL PROTECTED]
  For additional commands, e-mail:
  [EMAIL PROTECTED]
 
 
 
 
 __
 Do You Yahoo!?
 Tired of spam?  Yahoo! Mail has the best spam protection around
 http://mail.yahoo.com
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 


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



Re: question about deployment (including executables in war)

2005-07-19 Thread Alon Belman
Murad,

I'm not 100% sure what you're asking -- like what do you mean by jar
strips the execute file permissions from my programs? -- but i'm
assuming you cant do it.   In fact, I will be more than a little
alarmed if a packaged web app can include and run arbitrary
executables unless specifically allowed to so by its server's
SecurityManager, or if the server is running without a
SecurityManager.  That is, you cannot do it unless you configure it
OUTSIDE your web application.

Hope this helps,
Alon



On 7/17/05, Murad Nayal [EMAIL PROTECTED] wrote:
 
 
 Hi Everybody,
 
 I need to include executable programs as part of my web application. in
 development I created a directory WEB-INF/bin where I kept copies of the
 programs I need. problem is when I create a war file for my application,
 jar strips the execute file permissions from my programs. is there any
 way around this at all where I would still have my application packaged
 as a single war file with the necessary executables (with the correct
 permissions).
 
 many thanks
 Murad Nayal
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 


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



RE: Tomcat Service isn't reading application specific log4j.properties

2005-07-19 Thread Brian Stephens
Sorry, I managed to edit some really pertinent information from my
previous post.  

Logging is working at some level through the service.  However, it
doesn't seem to be picking up anything from log4j.properties, whether
it's in %CATALINA_HOME%\common\classes or MY_WEB_APP\WEB-INF\classes.


When I run tomcat using startup.bat or catalina.bat, the
log4j.properties are read as expected and logging works fine.  It's just
that when I run as a service, the following logs are all I get:
jakarta_service_datestamp.log, stdout_datestamp.log and
stderr_datestamp.log.  There is a certain amount of logging
configuration specified for the service itself in the documentation
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/windows-service-howto.ht
ml, but none of it refers to integrating with log4j.

-Original Message-
From: skausl [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, July 19, 2005 2:19 PM
To: 'Tomcat Users List'
Subject: RE: Tomcat Service isn't reading application specific
log4j.properties


I have log4j-1.2.11.jar in Tomcat\common\lib and log4j.properties in
Tomcat\common\classes\.

 -Original Message-
 Sorry if this is an oft-repeated question.  Digging through old 
 archives of this list and Google haven't turned up anything directly 
 related.
 
 I'm trying to run Tomcat 5.5.9 as a windows service (installed it 
 using service.bat), but for some unknown reason, it does not pick up 
 the log4j.properties files located in my applications WEB-INF\classes 
 directory.  As far as I can tell, the java options, classpath and 
 startup class are identical for both.  Is this a limitation/weakness 
 of the Windows Service or do I have something mis-configured?
 
 Thank You.
 Brian


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


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



Re: Unable to use Python/CGI from Tomcat....

2005-07-19 Thread Sweetshaipnai17
In a message dated 7/19/2005 2:56:49 PM Pacific Standard Time, 
[EMAIL PROTECTED] writes:
[EMAIL PROTECTED]


tomcat as service under linux how-to

2005-07-19 Thread dummy
Hi,
 
I would like to know how to start-up tomcat as services under LINUX and at
the same time start-up apache after tomcat has started.
How to check whether tomcat is already started before apache is started ?
 
I don't have this on windows system.


RE: question about deployment (including executables in war)

2005-07-19 Thread Richard Mixon (qwest)
Murad/Alon,

This has nothing to do with a SecurityManager. Murad is trying to run
the executables on the server - from one of his servlets I assume.

The problem is the fact that a war files is basically just a zip file.
It does not maintain the file attributes that are specific to a
particular operating system (e.g. execute, read-only, write, etc.).
Other archive formats do this (e.g. tar and Windows backup archives).

I believe the user's umask setting is probably used to set the
permissions - but Tomcat might do something different. Regardless, even
if Tomcat honors the umask setting, you would not want to change this
such that all files were marked executable when the jar was
uncompressed.

I am not sure you have much option other than to have a custom ant
script that alters the permissions after the files are deployed from the
war file. The jakarta-tomcat-5.5.x-deployer has a deployment script
(build.xml) that should be a good starting point.

Hope this helps - Richard 

-Original Message-
From: Alon Belman [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, July 19, 2005 4:44 PM
To: Tomcat Users List; [EMAIL PROTECTED]
Subject: Re: question about deployment (including executables in war)

Murad,

I'm not 100% sure what you're asking -- like what do you mean by jar
strips the execute file permissions from my programs? -- but i'm
assuming you cant do it.   In fact, I will be more than a little
alarmed if a packaged web app can include and run arbitrary executables
unless specifically allowed to so by its server's SecurityManager, or if
the server is running without a SecurityManager.  That is, you cannot do
it unless you configure it OUTSIDE your web application.

Hope this helps,
Alon



On 7/17/05, Murad Nayal [EMAIL PROTECTED] wrote:
 
 
 Hi Everybody,
 
 I need to include executable programs as part of my web application. 
 in development I created a directory WEB-INF/bin where I kept copies 
 of the programs I need. problem is when I create a war file for my 
 application, jar strips the execute file permissions from my programs.

 is there any way around this at all where I would still have my 
 application packaged as a single war file with the necessary 
 executables (with the correct permissions).
 
 many thanks
 Murad Nayal
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 


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




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



Re: tomcat as service under linux how-to

2005-07-19 Thread Foo Shyn
Put a script that starts Apache and Tomcat into the /etc/rc.d/init.d folder.
U can modify the rc.local script to run the script when Linux boot.
U can run a ps -ef | grep command to check whether Tomcat is running before
u start running Apache. By the way, y do u need to start Tomcat first before
starting Apache? if u wanna do connection between Apache and Tomcat using
mod_jk, i think that starting Apache first before starting Tomcat is the
way, just my opinion though.

BTW, Google is your friend.

F.S.

- Original Message - 
From: dummy [EMAIL PROTECTED]
To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Wednesday, July 20, 2005 9:29 AM
Subject: tomcat as service under linux how-to


 Hi,

 I would like to know how to start-up tomcat as services under LINUX and at
 the same time start-up apache after tomcat has started.
 How to check whether tomcat is already started before apache is started ?

 I don't have this on windows system.



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



Re: tomcat as service under linux how-to

2005-07-19 Thread Luis Durán
dummy wrote:
 Hi,
  
 I would like to know how to start-up tomcat as services under LINUX and at
 the same time start-up apache after tomcat has started.
 How to check whether tomcat is already started before apache is started ?
  
 I don't have this on windows system.
 
You could use netstat -tlp as root and see the ports where you have
configured tomcat on open (listening), you will see a java-* process
name too. This is one way, maybe not the best, but works.

-- 

Luis Edgardo Durán Lebis
Soporte Técnico y Sistemas
http://mipagina.cantv.net/elebis
[EMAIL PROTECTED]
0416-7580991


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



Re: Connection pool exhausted

2005-07-19 Thread Nikola Milutinovic

Tony Smith wrote:


I am runing tomcat 5.0 + postgresql. I set my
connection pool in server.xml as:

   Resource
 name=jdbc/mysource
 type=javax.sql.DataSource
 password=
 driverClassName=org.postgresql.Driver
 maxIdle=100
 maxWait=5000
 validationQuery=select * from test
 



For PostgreSQL (and MySQL, too), this is better done via SELECT 
version(), just an observation.



 username=
 url=jdbc:postgresql://localhost:5432/mydb
 maxActive=100/
 



You can add parameters, like removeAbandoned to remove hanging 
connections.



I call it from my servlet as:

public Connection getConnection(){
   try{
   Context initCtx = new InitialContext();
   Context envCtx =
(Context)initCtx.lookup(java:comp/env);
DataSource ds =
(DataSource)envCtx.lookup(jdbc/mysource);
DatabaseManager.initDataSource(ds);
return ds.getConnection();
}catch(Exception e){
   e.printStackTrace();
   }

   return null;
}


I use the connection as:

Connection connection = getConnection();

//jdbc

//I did not call connection.close(). Should I?
 



YES! The Connection you get from this is a wrapper class, that will 
actually return the connection to the pool, when you call close() on it.



Then, I can run my web app. But not for long. I got
the following exception after browse a few pages:

org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot
get a connection, pool exhausted
 



Always close ResultSets, Statements and Connections - in that order.

This code will illustrate it for you:

PreparedStatement pstat = null;
ResultSet rs = null;
try {
   pstat = conn.prepareStatement( SELECT ... );
   pstat.setInt( 1, x );
   ...
   rs = pstat.execute();
   ...
} catch (SQLException ex) {
   ...
} finally {
   if (rs != null) {
  try {
 rs.close();
  } catch (SQLException ex1) {}
   }
   if (pstat != null) {
  try {
 pstat.close();
  } catch (SQLException ex1) {}
   }
   if (conn != null) {
  try {
 conn.close();
  catch (SQLException ex1) {}
   }
}

Nix.

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