Re: problem with mod_jk and tomcat-host downtime on solaris

2008-01-24 Thread Rainer Jung

Christian Schausberger wrote:

Rainer Jung wrote:

I would start adding a prepost_timeout. See:

http://tomcat.apache.org/connectors-doc/generic_howto/timeouts.html
and
http://tomcat.apache.org/connectors-doc/reference/workers.html


Maybe I misunderstood this directive. connect_timeout only applies after
the TCP connection has been established. I thought the order in which
those timeouts apply is:
1.) socket_timeout
2.) connect_timeout
3.) prepost_timeout


socket_timeout is a low level socket timeout (sic!).
So whenever we read from the socket, the timer starts and if it fires, 
then we get an error. The connection can not be used any more afterwards.


connect_timeout is higher level: *After* TCP connect we send a tiny 
packet to Tomcat that is directly answered by the connector. We call it 
cping/cpong. If this answer from Tomcat does not come back within the 
connect_timeout, we think that we either are not connected to Tomcat or 
it is stuck.


prepost_timeout is similar to connect_timeout, but it is used in the 
situation, where the connection has already been established for some 
previous request and we are going to reuse (what we are supposed to do a 
lot, because AJP13 uses persistent connections). We send a cping and 
wait for cpong before each request when prepost_timeout is set. Such 
behaviour is very common with other persistent connection technologies 
like e.g. database connection pools.


What I'm actually not sure about, is how short socket_timeout and longer 
other timeouts go together. When we wait for cpong answers or a backend 
reply, we use the select() call and I'm not sure if a socket_timeout 
will fire during select (in our case it would be better if not).




Does prepost_timeout actually work even though the underlying TCP
connection can not be established?


See above, prepost gets used when we reuse an established connection to 
make sure, that the backend is still there and able to answer.



Caution: there's a bug in 1.2.25 that makes max_reply_timouts useless.
Consider upgrading to 1.2.26 (even if this is not the solution to the
problem you are asking for).

I will upgrade as soon as possible.

Thanks,

Christian


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



Problem with protecting pages in Tomcat 5.5

2008-01-24 Thread Diogenes Gomes
Hi,

I have the following web.xml
=
web-app ...
display-nametesteweb/display-name

security-constraint
web-resource-collection
web-resource-nameTeste/web-resource-name
url-pattern/*/url-pattern
/web-resource-collection
auth-constraint
role-name*/role-name
/auth-constraint
user-data-constraint
transport-guaranteeNONE/transport-guarantee
/user-data-constraint
/security-constraint

login-config
auth-methodFORM/auth-method
form-login-config
form-login-page/login.jsp/form-login-page
form-error-page/erro.html/form-error-page
/form-login-config
/login-config
welcome-file-list
welcome-fileindex.html/welcome-file
/welcome-file-list
/web-app
=

and the following contex.xml
=
?xml version=1.0 encoding=UTF-8?
Context debug=99 docBase=${catalina.home}/webapps/testeweb
path=/testeweb

Realm className=org.apache.catalina.realm.JDBCRealm
driverName=oracle.jdbc.driver.OracleDriver
connectionURL=jdbc:oracle:thin:@localhost:1521/XE
connectionName=saps connectionPassword=saps 
userTable=USUARIODOSISTEMA
userNameCol=NOME userCredCol=NOME
userRoleTable=PAPEISDOUSUARIO roleNameCol=NOMEDOPAPEL /
/Context
=


The application runs ok in Tomcat 5.0 but in 5.5.20 and 5.5.25 I have
the error page
=
HTTP Status 403 - Access to the requested resource has been denied



type Status report

message Access to the requested resource has been denied

description Access to the specified resource (Access to the requested
resource has been denied) has been forbidden.



Apache Tomcat/5.5.20
=

and a log segment (the very final lines in the log's file before the HTTP 403)
=
...
DEBUG http-80-Processor24
org.apache.catalina.authenticator.FormAuthenticator - Save request in
session 'C47C8398E47E5894DB8531EDBC2E0630'
DEBUG http-80-Processor24
org.apache.catalina.authenticator.FormAuthenticator - Authenticating
username 'usuario1'
DEBUG http-80-Processor24
org.apache.catalina.authenticator.FormAuthenticator - Authentication
of 'usuario1' was successful
DEBUG http-80-Processor24
org.apache.catalina.authenticator.FormAuthenticator - Redirecting to
original '/testeweb/'
DEBUG http-80-Processor24
org.apache.catalina.authenticator.FormAuthenticator - Restore request
from session 'C47C8398E47E5894DB8531EDBC2E0630'
DEBUG http-80-Processor24
org.apache.catalina.authenticator.FormAuthenticator - Proceed to
restored request
=

It seems to be a bug. Does anybody know a workaround? Is there a
mistake in my configuration files?

Thanks in advance.
Diogenes Gomes

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



find out the possible bottleneck webapp

2008-01-24 Thread maggie
Hi ,all

I deploy many web applications on Tomcat.
But sometimes the response time of Tomcat is very long. At that time,
the CPU usage is very high.

Is there any tool for me to find out which web application consumes most
of the CPU resource?

Is there any tool to provide such information Remotely even if the
workload of Tomcat is very heavy?

Any hint is welcome. Thanks in advance.

-- 
Sincerely,
Maggie


Server 2008 x64 + Java + Tomcat - does not work

2008-01-24 Thread mor_feusz

Hi all. 
I have installed test x64 environment. Server 2008. I have installed latest
Tomcat as well (6.0) and latest Java (1.6). 
I had ot install JAVA 32bit - Tomcat did not wanted to start. I know that
service is 32 bit (i can see in task manager *32 at the end) and it can not
start Java 64 bit. I have tried install JDK and JRE 64 bit and det JAVA_HOME
to point to JDK 1.6 x64 and after configure Tomcat to use JRE x64. 
The problem is - does not want to work. I have tried lots of things i have
found but none of those works. 
Could anyone help, please?


-- 
View this message in context: 
http://www.nabble.com/Server-2008-x64-%2B-Java-%2B-Tomcat---does-not-work-tp15064142p15064142.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


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



RE: Problem with protecting pages in Tomcat 5.5

2008-01-24 Thread Caldarale, Charles R
 From: Diogenes Gomes [mailto:[EMAIL PROTECTED] 
 Subject: Problem with protecting pages in Tomcat 5.5
 
   auth-constraint
   role-name*/role-name
   /auth-constraint

IIRC, 5.0 misinterpreted a role-name setting of *; this was corrected
in 5.5 and above.  The asterisk does not mean any role, but rather
all defined roles.  (See section 12 of the servlet spec.)  You need to
provide a set of valid roles via security-role in your web.xml file.

 Context debug=99 docBase=${catalina.home}/webapps/testeweb
   path=/testeweb

Take out the docBase and path attributes - they're not allowed when the
Context element is in META-INF/context.xml (where it should be).

 - Chuck


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

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



RE: Running multiple tomcat instances with Tomcat 6.0.14

2008-01-24 Thread Caldarale, Charles R
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
 Subject: Running multiple tomcat instances with Tomcat 6.0.14
 
 conf
   Catalina
 localhost
 context.xml
 
 Contents of context.xml are as follows -
 Context path= docBase=D:/test/LATEST/docs debug=0
 privileged=true allowLinking=true
 /Context

The above is incorrect, on all Tomcat levels.  The fact that it happened
to do anything at all on older versions just demonstrates that bugs have
been fixed in the newer ones.

The Context element in conf/Catalina/localhost/context.xml is intended
to provide attributes shared by all webapps deployed under the related
Host, not the settings for an individual webapp.  If you want to
specify the location of the defautl webapp, remove the path attribute
(it's not allowed here), and change the name of that file to ROOT.xml
(case sensitive, even on Windows).  Since you're defining the default
webapp, delete any ROOT directory or ROOT.war file under the Host
appBase directory.

 - Chuck


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

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



Re: Problem with protecting pages in Tomcat 5.5

2008-01-24 Thread Diogenes Gomes
Thank you very much Caldarale.

Please, do you know how to define any role? The framework I use
takes care of authorization (based on service's methods). I only need
to authenticate the user, otherwise I would double the access
configuration.

Diogenes

2008/1/24, Caldarale, Charles R [EMAIL PROTECTED]:
  From: Diogenes Gomes [mailto:[EMAIL PROTECTED]
  Subject: Problem with protecting pages in Tomcat 5.5
 
auth-constraint
role-name*/role-name
/auth-constraint

 IIRC, 5.0 misinterpreted a role-name setting of *; this was corrected
 in 5.5 and above.  The asterisk does not mean any role, but rather
 all defined roles.  (See section 12 of the servlet spec.)  You need to
 provide a set of valid roles via security-role in your web.xml file.

  Context debug=99 docBase=${catalina.home}/webapps/testeweb
path=/testeweb

 Take out the docBase and path attributes - they're not allowed when the
 Context element is in META-INF/context.xml (where it should be).

  - Chuck


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

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



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



Tomcat memory leak?

2008-01-24 Thread Ofer Kalisky

Hi,

I know it's weird, but I'm doing the simplest thing and can't believe there
such a leak that I'm the first one to notice. I bet it's my bad, please
someone explain, what I'm doing wrong...

I created the simplest JSP and when I load test it - tomcat (6.0.14,
jre1.6.0_03) goes to 99.9% memory use in a few minutes (If I raise the max
heap size it takes longer, but it happens several minutes afterwards), and
when I stop bombarding it, it doesn't return to the usual percentage.

When I try the same with an HTML instead of a JSP, that returns exactly the
same - it stays on 12%-20%, cleans with the garbage collector, and returns
to the usual percentage (about 12%).

I tried profiling with several plugins and external programs, but I really
can't understand what's going on. They tell me that most of the allocated
bytes are char[], but I'm not sure who's the allocator and if there's
anything I can do about it...

Attached are:
1. a test in python that bombards the tomcat,
2. a war with both something.jsp and something.html (they are both the same,
but when I bombard something.html everything is ok, and when I do the same
for something.jsp - the problem occurs)

Can anyone tell me what I'm doing wrong? does it happen to you too?

Thanks, Ofer.

http://www.nabble.com/file/p15065013/LoadTest.war LoadTest.war 
http://www.nabble.com/file/p15065013/load.py load.py 
-- 
View this message in context: 
http://www.nabble.com/Tomcat-memory-leak--tp15065013p15065013.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


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



RE: Problem with protecting pages in Tomcat 5.5

2008-01-24 Thread Caldarale, Charles R
 From: Diogenes Gomes [mailto:[EMAIL PROTECTED] 
 Subject: Re: Problem with protecting pages in Tomcat 5.5
 
 Please, do you know how to define any role?

I don't believe the servlet spec allows for such a weak constraint.  You
may want to consider using programmatic authentication (as defined in
the servlet spec) rather than declarative.

Take a look at:
http://sourceforge.net/projects/securityfilter

Although the last update was in 2004, it's recently become active again
(thank you, Chris), and is much more flexible than what's allowed in the
spec.

 - Chuck


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

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



Re: find out the possible bottleneck webapp

2008-01-24 Thread Martin Gainty
you will need to allow remote access to tomcat jmx via configured JAVA_OPTS
such as
-Dcom.sun.management.jmxremote

Complete details available at
http://java.sun.com/j2se/1.5.0/docs/guide/management/agent.html

Martin-
- Original Message -
From: David Delbecq [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Thursday, January 24, 2008 8:42 AM
Subject: Re: find out the possible bottleneck webapp


 En l'instant précis du 24/01/08 14:32, maggie s'exprimait en ces termes:
  Hi ,all
 
  I deploy many web applications on Tomcat.
  But sometimes the response time of Tomcat is very long. At that time,
  the CPU usage is very high.
 
  Is there any tool for me to find out which web application consumes most
  of the CPU resource?
 
  Is there any tool to provide such information Remotely even if the
  workload of Tomcat is very heavy?
 
  Any hint is welcome. Thanks in advance.
 
 

 Any profiler should do the work. Here we use JProfiler. However, running
 this in production can prove, in itself, to be a bottleneck. This
 depends on how much informations you requires.

 --
 http://www.devlog.be (a belgian developer's logs)



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




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



RE: load balancing issue

2008-01-24 Thread Hehl, Thomas
Yes, struts and spring together. Dropping struts soon.

The thing I don't understand is that if I connect to one of the servers'
tomcat instance directly, it works fine. The error only shows up when I go
through httpd as the load balancer.

-Original Message-
From: Len Popp [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, January 23, 2008 4:20 PM
To: Tomcat Users List
Subject: Re: load balancing issue

So it seems that the application is sending a redirect to
/myapp/myapp/index.html. You'll have to figure out why that is.
(Judging from the URLs you mention it looks like you're using Struts,
but I'm not an expert on that.)

If you want to see whether the server is sending a redirect response,
use a browser plug-in such as Live HTTP Headers or ieHTTPHeaders to
look at the browser requests and server responses.
-- 
Len

On Jan 23, 2008 3:30 PM, Hehl, Thomas [EMAIL PROTECTED] wrote:
 The button will, in the example with questionnaire, point to
 ../do/workflowMgr?flowName=questionnaire. The good URL would be
 server/myapp/do/workflowMgr?flowName=questionnaire. That's why I don't
 understand why it's running to /myapp/myapp/index.html. Neither doubling
up
 the app name or the index.html make any sense at all to me.


 -Original Message-
 From: Len Popp [mailto:[EMAIL PROTECTED]
 Sent: Wednesday, January 23, 2008 3:07 PM
 To: Tomcat Users List
 Subject: Re: load balancing issue

 The obvious question is, does /myapp/myapp/index.html actually exist
 on the server? If the button sends you to the wrong URL then of course
 you get a 404. So the first place to look is the web page with that
 button on it.

 There are other things that could cause problems like that, but
 without details about your setup I don't want to make wild guesses.
 --
 Len

 On Jan 23, 2008 1:13 PM, Hehl, Thomas [EMAIL PROTECTED] wrote:
  I am running apache httpd 2.0.46 on a redhat server as a load balancer
for
 a
  tomcat 6 cluster, also on redhat servers.
 
 
 
  I point my browser to the home page on the load balancer server and it
  returns the index.html just fine. I log into the application, again,
fine.
 I
  click on one of the menu items, which works, then I hit a button and I
get
 a
  404. For example, if the application was called myapp, the error says:
 
 
 
  HTTP Status 404 - /myapp/myapp/index.html
 
_
 
  type Status report
 
  message /myapp/myapp/index.html
 
  description The requested resource (/myapp/myapp/index.html) is not
  available.
 
_
 
  Apache Tomcat/6.0.14
 
  Any ideas as to what might cause this error that deep?
 
 
 
  Thanks!
 
 
 
 
 
  Thom Hehl
  Sr. eJuror Architect
 
  * Office (859) 277-8800 x 144
 
  * [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]
  ACS, Inc.
 
  Government Solutions
 
  1733 Harrodsburg Road
  Lexington, KY 40504-3617
 
  This e-mail message, including any attachments, is for the sole use of
the
  intended recipient(s) and may contain confidential and privileged
  information. Any unauthorized review, use, disclosure or distribution is
  prohibited. If you are not the intended recipient, please contact the
 sender
  by reply e-mail and destroy all copies of the original message and
notify
  sender via e-mail at [EMAIL PROTECTED]
  mailto:[EMAIL PROTECTED]  or by telephone at 859-277-8800 ext.
 144.
  Thank you.
 
 
 
 

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

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



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

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



Re: Problem with protecting pages in Tomcat 5.5

2008-01-24 Thread David Smith
I would think the simplest way to go is to define a role and add all 
registered users to it.  Nothing says a user can't have more than one role.


--David

Diogenes Gomes wrote:


Thank you very much Caldarale.

Please, do you know how to define any role? The framework I use
takes care of authorization (based on service's methods). I only need
to authenticate the user, otherwise I would double the access
configuration.

Diogenes

2008/1/24, Caldarale, Charles R [EMAIL PROTECTED]:
 


From: Diogenes Gomes [mailto:[EMAIL PROTECTED]
Subject: Problem with protecting pages in Tomcat 5.5

 auth-constraint
 role-name*/role-name
 /auth-constraint
 


IIRC, 5.0 misinterpreted a role-name setting of *; this was corrected
in 5.5 and above.  The asterisk does not mean any role, but rather
all defined roles.  (See section 12 of the servlet spec.)  You need to
provide a set of valid roles via security-role in your web.xml file.

   


Context debug=99 docBase=${catalina.home}/webapps/testeweb
 path=/testeweb
 


Take out the docBase and path attributes - they're not allowed when the
Context element is in META-INF/context.xml (where it should be).

- Chuck


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

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


   



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

 




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



Re: problem with mod_jk and tomcat-host downtime on solaris

2008-01-24 Thread Christian Schausberger
Rainer Jung wrote:
 Christian Schausberger wrote:
 Rainer Jung wrote:
 I would start adding a prepost_timeout. See:

 http://tomcat.apache.org/connectors-doc/generic_howto/timeouts.html
 and
 http://tomcat.apache.org/connectors-doc/reference/workers.html

 Maybe I misunderstood this directive. connect_timeout only applies after
 the TCP connection has been established. I thought the order in which
 those timeouts apply is:
 1.) socket_timeout
 2.) connect_timeout
 3.) prepost_timeout

 socket_timeout is a low level socket timeout (sic!).
 So whenever we read from the socket, the timer starts and if it fires,
 then we get an error. The connection can not be used any more afterwards.

If this is a matter of starting a timer after a read from the socket,
why should this not be supported on Solaris?

 prepost_timeout is similar to connect_timeout, but it is used in the
 situation, where the connection has already been established for some
 previous request and we are going to reuse (what we are supposed to do
 a lot, because AJP13 uses persistent connections). We send a cping and
 wait for cpong before each request when prepost_timeout is set. Such
 behaviour is very common with other persistent connection technologies
 like e.g. database connection pools.


 Does prepost_timeout actually work even though the underlying TCP
 connection can not be established?
 See above, prepost gets used when we reuse an established connection
 to make sure, that the backend is still there and able to answer.


I have tried prepost as you suggested in your first reply but it had no
effect because of the reasons you just explained. Upgrading to
mod_jk-1.2.26 also had no effect.  I assume reply_timeout will also rely
on an established ajp connection.

Regards,

Christian

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



Re: Tomcat memory leak?

2008-01-24 Thread Ofer Kalisky
I think one of the files wasn't attached for some reason...
  - Original Message - 
  From: Ofer Kalisky 
  To: users@tomcat.apache.org 
  Sent: Thursday, January 24, 2008 4:51 PM
  Subject: Tomcat memory leak?


  Hi,

  I know it's weird, but I'm doing the simplest thing and can't believe there 
such a leak that I'm the first one to notice. I bet it's my bad, please someone 
explain, what I'm doing wrong...

  I created the simplest JSP and when I load test it - tomcat (6.0.14, 
jre1.6.0_03) goes to 99.9% memory use in a few minutes (If I raise the max heap 
size it takes longer, but it happens several minutes afterwards), and when I 
stop bombarding it, it doesn't return to the usual percentage.

  When I try the same with an HTML instead of a JSP, that returns exactly the 
same - it stays on 12%-20%, cleans with the garbage collector, and returns to 
the usual percentage (about 12%).

  I tried profiling with several plugins and external programs, but I really 
can't understand what's going on. They tell me that most of the allocated bytes 
are char[], but I'm not sure who's the allocator and if there's anything I 
can do about it...

  Attached are:
  1. a test in python that bombards the tomcat,
  2. a war with both something.jsp and something.html (they are both the same, 
but when I bombard something.html everything is ok, and when I do the same for 
something.jsp - the problem occurs)

  Can anyone tell me what I'm doing wrong? does it happen to you too?

  Thanks, Ofer.


--


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

Re: Tomcat memory leak?

2008-01-24 Thread mgainty
Good Morning Ofer

I dont see attachement of /LoadTest/something.jsp

Martin-
  - Original Message - 
  Wrom: FPEGAUTFJMVRESK
  To: users@tomcat.apache.org 
  Sent: Thursday, January 24, 2008 9:51 AM
  Subject: Tomcat memory leak?


  Hi,

  I know it's weird, but I'm doing the simplest thing and can't believe there 
such a leak that I'm the first one to notice. I bet it's my bad, please someone 
explain, what I'm doing wrong...

  I created the simplest JSP and when I load test it - tomcat (6.0.14, 
jre1.6.0_03) goes to 99.9% memory use in a few minutes (If I raise the max heap 
size it takes longer, but it happens several minutes afterwards), and when I 
stop bombarding it, it doesn't return to the usual percentage.

  When I try the same with an HTML instead of a JSP, that returns exactly the 
same - it stays on 12%-20%, cleans with the garbage collector, and returns to 
the usual percentage (about 12%).

  I tried profiling with several plugins and external programs, but I really 
can't understand what's going on. They tell me that most of the allocated bytes 
are char[], but I'm not sure who's the allocator and if there's anything I 
can do about it...

  Attached are:
  1. a test in python that bombards the tomcat,
  2. a war with both something.jsp and something.html (they are both the same, 
but when I bombard something.html everything is ok, and when I do the same for 
something.jsp - the problem occurs)

  Can anyone tell me what I'm doing wrong? does it happen to you too?

  Thanks, Ofer.


--


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

Re: Tomcat memory leak?

2008-01-24 Thread Ofer Kalisky

Change file ext to zip...

- Original Message - 
From: Ofer Kalisky [EMAIL PROTECTED]

To: Tomcat Users List users@tomcat.apache.org
Sent: Thursday, January 24, 2008 5:08 PM
Subject: Re: Tomcat memory leak?



I think the mailing list blocks war files...

trying with zip...

- Original Message - 
From: [EMAIL PROTECTED]

To: Tomcat Users List users@tomcat.apache.org
Sent: Thursday, January 24, 2008 5:00 PM
Subject: Re: Tomcat memory leak?


Good Morning Ofer

I dont see attachement of /LoadTest/something.jsp

Martin-
 - Original Message - 
 Wrom: FPEGAUTFJMVRESK

 To: users@tomcat.apache.org
 Sent: Thursday, January 24, 2008 9:51 AM
 Subject: Tomcat memory leak?


 Hi,

 I know it's weird, but I'm doing the simplest thing and can't believe
there such a leak that I'm the first one to notice. I bet it's my bad,
please someone explain, what I'm doing wrong...

 I created the simplest JSP and when I load test it - tomcat (6.0.14,
jre1.6.0_03) goes to 99.9% memory use in a few minutes (If I raise the max
heap size it takes longer, but it happens several minutes afterwards), and
when I stop bombarding it, it doesn't return to the usual percentage.

 When I try the same with an HTML instead of a JSP, that returns exactly
the same - it stays on 12%-20%, cleans with the garbage collector, and
returns to the usual percentage (about 12%).

 I tried profiling with several plugins and external programs, but I 
really

can't understand what's going on. They tell me that most of the allocated
bytes are char[], but I'm not sure who's the allocator and if there's
anything I can do about it...

 Attached are:
 1. a test in python that bombards the tomcat,
 2. a war with both something.jsp and something.html (they are both the
same, but when I bombard something.html everything is ok, and when I do 
the

same for something.jsp - the problem occurs)

 Can anyone tell me what I'm doing wrong? does it happen to you too?

 Thanks, Ofer.


--


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









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

PKá88҆ðl¨Ûload.py5ŽÁ
[EMAIL PROTECTED]
þÃc P
®jÑ¢…?`6é‹qÞ4ó¢ßo4۞{÷âdÉ1ŒÌVã-‰“¡™ÄŸµ‚²Nâ¨'c\;ù¹m¯‡€TÏHšúNä¹®d%E¶¹S¯·òœŠÓ±;Ņº{HáiR¢ò§·‹àÊ0°Xƒb§¼%ãU:'ø€a{)¡
  ϲùQdœó l¡üÏöš~êPK¯88I^9™.LoadTest.warðffaàÂu[EMAIL 
PROTECTED]Ý\ƒCô|Ýûž9íã­«w‘×[Wëܙó›ƒ®?xZtÎSG﯇ÎÉ
Až[EMAIL PROTECTED] wu۔“™¤Ï[EMAIL 
PROTECTED](@Õˏ¤·5I¯7§wB¼÷a‘£óEÿð©¾÷ܵ‹]óe›BSÀü9/nŸ˜µÛTÕ÷pÞ¶kùùVf[•¶åO/®û~_ðô:³‹‚ßVHϞ(Ùíɲ-cʶÝ={Öɽ”ÔË[çÊ-­5·{Ë©Ò9ïæFÛÛNx®å¬§HZ䏗{½-×?
 
4²‰31åÛ~b5˃3Ke_éoˍ¾voSÚþǞ2çü.þ4%À{•nUf÷îÒ.uÃ|®—þÙîa®Êvöû·ú]+¾¶PéáUí…VÊö+¦š~qºç±•éKÓÿ2'µ–]WÙV\|Q]ª¡¿%ôÂÆK×Ý4~䷚¸æBï$®mŸþla®;[EMAIL
 PROTECTED]
¨áÇÄÅù¹©%™yéz%¹9›Ojœ»ññÓMž§üW²\Ìü麓«ó¤ê̟•Û¼ÎIvV¾\yîgeæ̗U‘GY½Dõú¸ÌfV².UåRÊºr›—êJQU/®ÊΝ
eŽ^‹í›ë4Ñ.`ãòõ«ÕΦvZ.uèc”j˜9iæìYGõãùû{]WžœÉ:se¥*¯FV·÷äcÇI…µ¾à™Qÿõ 
#8IȉO³˜t0;#²—øВ/Š—²Š†œÐ9'R^$%w€”Ár}è9RI_rNbqqj1VýŒLˆâ9·‹0 l…   ²   
07ÀLçAѝ̀ZF ëù9µó£è\΀QB keäXàCÑüœ={ ë¥d½¼(zw1¡¥Ct7ƒÁ|ˉ¢µ‡)[EMAIL 
PROTECTED]|A+€¢ë/3fdx³²AÌç`¸
ô™-HPKá88҆ðl¨Û 
load.pyPK¯88I^9™. 
ÍLoadTest.warPKo-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Re: Tomcat memory leak?

2008-01-24 Thread Ofer Kalisky

Ok, since sending an attachment doesn't work,

simply create a webapp by the name of LoadTest and create two files inside:
something.jsp and something.html

the content of both files should be:

htmlbody//html


try the load.py with both:

import httplib

i = 0
while 1:
conn = httplib.HTTPConnection(localhost:8080)
conn.request(GET, /LoadTest/something.jsp)
r1 = conn.getresponse()
if (i % 500 == 0):
 print i
i = i + 1
conn.close()

sorry for any inconvenience

Ofer.

- Original Message - 
From: Ofer Kalisky [EMAIL PROTECTED]

To: Tomcat Users List users@tomcat.apache.org
Sent: Thursday, January 24, 2008 5:08 PM
Subject: Re: Tomcat memory leak?



I think the mailing list blocks war files...

trying with zip...

- Original Message - 
From: [EMAIL PROTECTED]

To: Tomcat Users List users@tomcat.apache.org
Sent: Thursday, January 24, 2008 5:00 PM
Subject: Re: Tomcat memory leak?


Good Morning Ofer

I dont see attachement of /LoadTest/something.jsp

Martin-
 - Original Message - 
 Wrom: FPEGAUTFJMVRESK

 To: users@tomcat.apache.org
 Sent: Thursday, January 24, 2008 9:51 AM
 Subject: Tomcat memory leak?


 Hi,

 I know it's weird, but I'm doing the simplest thing and can't believe
there such a leak that I'm the first one to notice. I bet it's my bad,
please someone explain, what I'm doing wrong...

 I created the simplest JSP and when I load test it - tomcat (6.0.14,
jre1.6.0_03) goes to 99.9% memory use in a few minutes (If I raise the max
heap size it takes longer, but it happens several minutes afterwards), and
when I stop bombarding it, it doesn't return to the usual percentage.

 When I try the same with an HTML instead of a JSP, that returns exactly
the same - it stays on 12%-20%, cleans with the garbage collector, and
returns to the usual percentage (about 12%).

 I tried profiling with several plugins and external programs, but I 
really

can't understand what's going on. They tell me that most of the allocated
bytes are char[], but I'm not sure who's the allocator and if there's
anything I can do about it...

 Attached are:
 1. a test in python that bombards the tomcat,
 2. a war with both something.jsp and something.html (they are both the
same, but when I bombard something.html everything is ok, and when I do 
the

same for something.jsp - the problem occurs)

 Can anyone tell me what I'm doing wrong? does it happen to you too?

 Thanks, Ofer.


--


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









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



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



Re: Tomcat memory leak?

2008-01-24 Thread Leon Rosenberg
I downloaded your example.
So you are telling us, that simply calling a JSP file with html markup
only and without any code kills your tomcat?

Regards
Leon

On Jan 24, 2008 4:19 PM, Ofer Kalisky [EMAIL PROTECTED] wrote:
 Ok, since sending an attachment doesn't work,

 simply create a webapp by the name of LoadTest and create two files inside:
 something.jsp and something.html

 the content of both files should be:

 htmlbody//html


 try the load.py with both:

 import httplib

 i = 0
 while 1:
  conn = httplib.HTTPConnection(localhost:8080)
  conn.request(GET, /LoadTest/something.jsp)
  r1 = conn.getresponse()
  if (i % 500 == 0):
   print i
  i = i + 1
  conn.close()

 sorry for any inconvenience

 Ofer.

 - Original Message -
 From: Ofer Kalisky [EMAIL PROTECTED]
 To: Tomcat Users List users@tomcat.apache.org

 Sent: Thursday, January 24, 2008 5:08 PM
 Subject: Re: Tomcat memory leak?


 I think the mailing list blocks war files...
 
  trying with zip...
 
  - Original Message -
  From: [EMAIL PROTECTED]
  To: Tomcat Users List users@tomcat.apache.org
  Sent: Thursday, January 24, 2008 5:00 PM
  Subject: Re: Tomcat memory leak?
 
 
  Good Morning Ofer
 
  I dont see attachement of /LoadTest/something.jsp
 
  Martin-
   - Original Message -
   Wrom: FPEGAUTFJMVRESK
   To: users@tomcat.apache.org
   Sent: Thursday, January 24, 2008 9:51 AM
   Subject: Tomcat memory leak?
 
 
   Hi,
 
   I know it's weird, but I'm doing the simplest thing and can't believe
  there such a leak that I'm the first one to notice. I bet it's my bad,
  please someone explain, what I'm doing wrong...
 
   I created the simplest JSP and when I load test it - tomcat (6.0.14,
  jre1.6.0_03) goes to 99.9% memory use in a few minutes (If I raise the max
  heap size it takes longer, but it happens several minutes afterwards), and
  when I stop bombarding it, it doesn't return to the usual percentage.
 
   When I try the same with an HTML instead of a JSP, that returns exactly
  the same - it stays on 12%-20%, cleans with the garbage collector, and
  returns to the usual percentage (about 12%).
 
   I tried profiling with several plugins and external programs, but I
  really
  can't understand what's going on. They tell me that most of the allocated
  bytes are char[], but I'm not sure who's the allocator and if there's
  anything I can do about it...
 
   Attached are:
   1. a test in python that bombards the tomcat,
   2. a war with both something.jsp and something.html (they are both the
  same, but when I bombard something.html everything is ok, and when I do
  the
  same for something.jsp - the problem occurs)
 
   Can anyone tell me what I'm doing wrong? does it happen to you too?
 
   Thanks, Ofer.
 
 
  --
 
 
   -
   To start a new topic, e-mail: users@tomcat.apache.org
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
 
 


 



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


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



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



Re: Tomcat memory leak?

2008-01-24 Thread Ofer Kalisky
That's what I'm saying, I've been sitting on this for two days and can't 
figure it out.
Do you mean to say that you tried it and even when accessing the JSP with 
the script - your memory stays low? What am I doing wrong then?


Please notice the tomcat version and the JRE version I stated (6.0.14, 
jre1.6.0_03).
One more thing: as I said, I'm trying it with 64M of max heap space, but I 
figured, if it goes to 99.9% mem use, there's no use raising it (even though 
I tried and it reached 99.9% after a short while)


Ofer.

- Original Message - 
From: Leon Rosenberg [EMAIL PROTECTED]

To: Tomcat Users List users@tomcat.apache.org
Sent: Thursday, January 24, 2008 5:25 PM
Subject: Re: Tomcat memory leak?



I downloaded your example.
So you are telling us, that simply calling a JSP file with html markup
only and without any code kills your tomcat?

Regards
Leon

On Jan 24, 2008 4:19 PM, Ofer Kalisky [EMAIL PROTECTED] wrote:

Ok, since sending an attachment doesn't work,

simply create a webapp by the name of LoadTest and create two files 
inside:

something.jsp and something.html

the content of both files should be:

htmlbody//html


try the load.py with both:

import httplib

i = 0
while 1:
 conn = httplib.HTTPConnection(localhost:8080)
 conn.request(GET, /LoadTest/something.jsp)
 r1 = conn.getresponse()
 if (i % 500 == 0):
  print i
 i = i + 1
 conn.close()

sorry for any inconvenience

Ofer.

- Original Message -
From: Ofer Kalisky [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org

Sent: Thursday, January 24, 2008 5:08 PM
Subject: Re: Tomcat memory leak?


I think the mailing list blocks war files...

 trying with zip...

 - Original Message -
 From: [EMAIL PROTECTED]
 To: Tomcat Users List users@tomcat.apache.org
 Sent: Thursday, January 24, 2008 5:00 PM
 Subject: Re: Tomcat memory leak?


 Good Morning Ofer

 I dont see attachement of /LoadTest/something.jsp

 Martin-
  - Original Message -
  Wrom: FPEGAUTFJMVRESK
  To: users@tomcat.apache.org
  Sent: Thursday, January 24, 2008 9:51 AM
  Subject: Tomcat memory leak?


  Hi,

  I know it's weird, but I'm doing the simplest thing and can't believe
 there such a leak that I'm the first one to notice. I bet it's my bad,
 please someone explain, what I'm doing wrong...

  I created the simplest JSP and when I load test it - tomcat (6.0.14,
 jre1.6.0_03) goes to 99.9% memory use in a few minutes (If I raise the 
 max
 heap size it takes longer, but it happens several minutes afterwards), 
 and

 when I stop bombarding it, it doesn't return to the usual percentage.

  When I try the same with an HTML instead of a JSP, that returns 
 exactly

 the same - it stays on 12%-20%, cleans with the garbage collector, and
 returns to the usual percentage (about 12%).

  I tried profiling with several plugins and external programs, but I
 really
 can't understand what's going on. They tell me that most of the 
 allocated

 bytes are char[], but I'm not sure who's the allocator and if there's
 anything I can do about it...

  Attached are:
  1. a test in python that bombards the tomcat,
  2. a war with both something.jsp and something.html (they are both the
 same, but when I bombard something.html everything is ok, and when I do
 the
 same for something.jsp - the problem occurs)

  Can anyone tell me what I'm doing wrong? does it happen to you too?

  Thanks, Ofer.


 --


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








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


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




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





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



Re: Tomcat memory leak?

2008-01-24 Thread Leon Rosenberg
i downloaded the war file and put it info webapps (it was the only webapp )
started tomcat (5.5.17)

started following in another shell:
while true; do wget http://localhost:8080/LoadTest/something.jsp; ; done

canceled after some thousands of iterations

i checked the memory usage via activity monitor (macosx) and tomcat
manager app. Both showed no changes.
Could it be that your python lib is keeping connection or something?
Have you checked via tomcat maanager how many connections you actually
have?
regards
Leon

On Jan 24, 2008 4:31 PM, Ofer Kalisky [EMAIL PROTECTED] wrote:
 That's what I'm saying, I've been sitting on this for two days and can't
 figure it out.
 Do you mean to say that you tried it and even when accessing the JSP with
 the script - your memory stays low? What am I doing wrong then?

 Please notice the tomcat version and the JRE version I stated (6.0.14,
 jre1.6.0_03).
 One more thing: as I said, I'm trying it with 64M of max heap space, but I
 figured, if it goes to 99.9% mem use, there's no use raising it (even though
 I tried and it reached 99.9% after a short while)

 Ofer.

 - Original Message -
 From: Leon Rosenberg [EMAIL PROTECTED]
 To: Tomcat Users List users@tomcat.apache.org

 Sent: Thursday, January 24, 2008 5:25 PM
 Subject: Re: Tomcat memory leak?


 I downloaded your example.
  So you are telling us, that simply calling a JSP file with html markup
  only and without any code kills your tomcat?
 
  Regards
  Leon
 
  On Jan 24, 2008 4:19 PM, Ofer Kalisky [EMAIL PROTECTED] wrote:
  Ok, since sending an attachment doesn't work,
 
  simply create a webapp by the name of LoadTest and create two files
  inside:
  something.jsp and something.html
 
  the content of both files should be:
 
  htmlbody//html
 
 
  try the load.py with both:
 
  import httplib
 
  i = 0
  while 1:
   conn = httplib.HTTPConnection(localhost:8080)
   conn.request(GET, /LoadTest/something.jsp)
   r1 = conn.getresponse()
   if (i % 500 == 0):
print i
   i = i + 1
   conn.close()
 
  sorry for any inconvenience
 
  Ofer.
 
  - Original Message -
  From: Ofer Kalisky [EMAIL PROTECTED]
  To: Tomcat Users List users@tomcat.apache.org
 
  Sent: Thursday, January 24, 2008 5:08 PM
  Subject: Re: Tomcat memory leak?
 
 
  I think the mailing list blocks war files...
  
   trying with zip...
  
   - Original Message -
   From: [EMAIL PROTECTED]
   To: Tomcat Users List users@tomcat.apache.org
   Sent: Thursday, January 24, 2008 5:00 PM
   Subject: Re: Tomcat memory leak?
  
  
   Good Morning Ofer
  
   I dont see attachement of /LoadTest/something.jsp
  
   Martin-
- Original Message -
Wrom: FPEGAUTFJMVRESK
To: users@tomcat.apache.org
Sent: Thursday, January 24, 2008 9:51 AM
Subject: Tomcat memory leak?
  
  
Hi,
  
I know it's weird, but I'm doing the simplest thing and can't believe
   there such a leak that I'm the first one to notice. I bet it's my bad,
   please someone explain, what I'm doing wrong...
  
I created the simplest JSP and when I load test it - tomcat (6.0.14,
   jre1.6.0_03) goes to 99.9% memory use in a few minutes (If I raise the
   max
   heap size it takes longer, but it happens several minutes afterwards),
   and
   when I stop bombarding it, it doesn't return to the usual percentage.
  
When I try the same with an HTML instead of a JSP, that returns
   exactly
   the same - it stays on 12%-20%, cleans with the garbage collector, and
   returns to the usual percentage (about 12%).
  
I tried profiling with several plugins and external programs, but I
   really
   can't understand what's going on. They tell me that most of the
   allocated
   bytes are char[], but I'm not sure who's the allocator and if there's
   anything I can do about it...
  
Attached are:
1. a test in python that bombards the tomcat,
2. a war with both something.jsp and something.html (they are both the
   same, but when I bombard something.html everything is ok, and when I do
   the
   same for something.jsp - the problem occurs)
  
Can anyone tell me what I'm doing wrong? does it happen to you too?
  
Thanks, Ofer.
  
  
   --
  
  
-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 
 
  
 
 
 
   -
   To start a new topic, e-mail: users@tomcat.apache.org
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
 
 
  -
  To start a new topic, e-mail: users@tomcat.apache.org
  To unsubscribe, e-mail: [EMAIL 

Re: Tomcat Windows Service Installer vs Core zip install xml

2008-01-24 Thread hoffmandirt

This issue was resolved by correctly utilizing the constructor of the
StreamSource object. It was expecting a String in URL/URI format and we were
passing in the file name only. The Zip download option of Tomcat did not
mind, but the Windows Service Installer option threw the Unknown protocol
c error. Does anyone know why this would be? Both installs were pointing to
the same JDK.
-- 
View this message in context: 
http://www.nabble.com/Tomcat-Windows-Service-Installer-vs-Core-zip-install-xml-tp15048926p15069803.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


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



Re: Server 2008 x64 + Java + Tomcat - does not work

2008-01-24 Thread mor_feusz

In addition: 

I have installed JAVA 1.6 and Tomcat 1.6 on my machine (XP) and all works
Perfect. 
I have installed 32bit version on 2008 x64 and it does work but not perfect. 

I can not start using (zipped version) startup.bat script. If i use Windows
installer it works. The problem is i wna to jump JAVA memory limits on 32bit
OS. 

I have Solaris 10 ad Tomcat 6 and Java 1.5 x64 and all works perfect. 

The 1 and only problem is with 2008 server. 
I want to resolve that issue 

Regards



mor_feusz wrote:
 
 Hi all. 
 I have installed test x64 environment. Server 2008. I have installed
 latest Tomcat as well (6.0) and latest Java (1.6). 
 I had ot install JAVA 32bit - Tomcat did not wanted to start. I know that
 service is 32 bit (i can see in task manager *32 at the end) and it can
 not start Java 64 bit. I have tried install JDK and JRE 64 bit and det
 JAVA_HOME to point to JDK 1.6 x64 and after configure Tomcat to use JRE
 x64. 
 The problem is - does not want to work. I have tried lots of things i have
 found but none of those works. 
 Could anyone help, please?
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Server-2008-x64-%2B-Java-%2B-Tomcat---does-not-work-tp15064142p15069817.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


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



Tomcat installation/deployment question

2008-01-24 Thread Sureka, Sushil



Hi,
 
We are intending to deploy our application on individual laptops
(to be used by field personnel who does not have internet connectivity
to connect to our central server). The idea is that a trimmed down
version of our core application will be deployed on individual laptops
running tomcat against a light weight Sybase database.
 
I wanted to see if you had any suggestions about - 
1. How best to deploy the initial version (5.5) of Tomcat on
individual machines  - We understand our options are Microsoft SMS, Java
Web Start application, shell script or Ant script to install Tomcat on
these laptop boxes. We are leaning towards Microsoft SMS since 
(a) It can easily mass deploy the app to hundreds of machine
(b) It is currently used in our organization to deploy some asp
application. 
If you believe there are downsides to this approach or other
approaches are better please let me know
 
2. How best to deploy the upgraded version (6.x or higher) - We
potentially could use the same approach as the first one, but wanted to
see if the opinion differs.
 
3. And finally the rollout of initial app and upgraded app
version. Again probably use the same approach as before but wanted to
throw this out there in case there are better ideas.
 
Please let me know your thoughts on this.
 
Sushil



RE: Tomcat Windows Service Installer vs Core zip install xml

2008-01-24 Thread Caldarale, Charles R
 From: hoffmandirt [mailto:[EMAIL PROTECTED] 
 Subject: Re: Tomcat Windows Service Installer vs Core zip install xml
 
 The Zip download option of Tomcat did not mind, but the 
 Windows Service Installer option threw the Unknown protocol
 c error.

Possibly due to the lack of a current directory setting when running as
a service.

 - Chuck


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

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



Re: Server 2008 x64 + Java + Tomcat - does not work

2008-01-24 Thread David kerber

mor_feusz wrote:
In addition: 


I have installed JAVA 1.6 and Tomcat 1.6 on my machine (XP) and all works
Perfect. 
I have installed 32bit version on 2008 x64 and it does work but not perfect. 


I can not start using (zipped version) startup.bat script. If i use Windows
installer it works. The problem is i want to jump JAVA memory limits on
32bit OS. 

I have Solaris 10 ad Tomcat 6 and Java 1.5 x64 and all works perfect. 

The 1 and only problem is with 2008 server. 
I want to resolve that issue 
  
Since Windows server 2008 is still in beta, it may be a windows issue 
rather than a TC issue.


D



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



RE: Tomcat Windows Service Installer vs Core zip install xml

2008-01-24 Thread hoffmandirt

That makes sense to me. Thanks Chuck.



Caldarale, Charles R wrote:
 
 From: hoffmandirt [mailto:[EMAIL PROTECTED] 
 Subject: Re: Tomcat Windows Service Installer vs Core zip install xml
 
 The Zip download option of Tomcat did not mind, but the 
 Windows Service Installer option threw the Unknown protocol
 c error.
 
 Possibly due to the lack of a current directory setting when running as
 a service.
 
  - Chuck
 
 
 THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
 MATERIAL and is thus for use only by the intended recipient. If you
 received this in error, please contact the sender and delete the e-mail
 and its attachments from all computers.
 
 -
 To start a new topic, e-mail: users@tomcat.apache.org
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Tomcat-Windows-Service-Installer-vs-Core-zip-install-xml-tp15048926p15070186.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


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



Re: Tomcat installation/deployment question

2008-01-24 Thread Gabe Wong

Sureka, Sushil wrote:


Hi,
	 
	We are intending to deploy our application on individual laptops

(to be used by field personnel who does not have internet connectivity
to connect to our central server). The idea is that a trimmed down
version of our core application will be deployed on individual laptops
running tomcat against a light weight Sybase database.
	 
	I wanted to see if you had any suggestions about - 
	1. How best to deploy the initial version (5.5) of Tomcat on

individual machines  - We understand our options are Microsoft SMS, Java
Web Start application, shell script or Ant script to install Tomcat on
these laptop boxes. We are leaning towards Microsoft SMS since 
	(a) It can easily mass deploy the app to hundreds of machine

(b) It is currently used in our organization to deploy some asp
application. 
	If you believe there are downsides to this approach or other

approaches are better please let me know
	 
	2. How best to deploy the upgraded version (6.x or higher) - We

potentially could use the same approach as the first one, but wanted to
see if the opinion differs.
	 
	3. And finally the rollout of initial app and upgraded app

version. Again probably use the same approach as before but wanted to
throw this out there in case there are better ideas.
	 
	Please let me know your thoughts on this.
	 
	Sushil



  

Sushil,

The Laptops I presume will be running Windows? If so which version(s)?


--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


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



RE: Tomcat installation/deployment question

2008-01-24 Thread Sureka, Sushil
XP but there is no guarantee that they won't go to Vista in a year
timeframe.

Sushil 

 -Original Message-
 From: Gabe Wong [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, January 24, 2008 11:54 AM
 To: Tomcat Users List
 Subject: Re: Tomcat installation/deployment question
 
 Sureka, Sushil wrote:
 
  Hi,
   
  We are intending to deploy our application on 
 individual laptops (to 
  be used by field personnel who does not have internet 
 connectivity to 
  connect to our central server). The idea is that a trimmed down 
  version of our core application will be deployed on 
 individual laptops 
  running tomcat against a light weight Sybase database.
   
  I wanted to see if you had any suggestions about - 
  1. How best to deploy the initial version (5.5) of Tomcat on 
  individual machines  - We understand our options are Microsoft SMS, 
  Java Web Start application, shell script or Ant script to install 
  Tomcat on these laptop boxes. We are leaning towards 
 Microsoft SMS since
  (a) It can easily mass deploy the app to hundreds of machine
  (b) It is currently used in our organization to deploy some asp 
  application.
  If you believe there are downsides to this approach or other 
  approaches are better please let me know
   
  2. How best to deploy the upgraded version (6.x or higher) - We 
  potentially could use the same approach as the first one, 
 but wanted 
  to see if the opinion differs.
   
  3. And finally the rollout of initial app and upgraded 
 app version. 
  Again probably use the same approach as before but wanted to throw 
  this out there in case there are better ideas.
   
  Please let me know your thoughts on this.
   
  Sushil
 
 

 Sushil,
 
 The Laptops I presume will be running Windows? If so which version(s)?
 
 
 --
 Regards
 
 Gabe Wong
 NGASI AppServer Manager
 JAVA AUTOMATION and SaaS Enablement
 a href=http://www.ngasi.comhttp://www.ngasi.com/a
 NEW! 8.0 - Centrally manage multiple physical servers
 
 
 -
 To start a new topic, e-mail: users@tomcat.apache.org To 
 unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

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



Re: Problem with protecting pages in Tomcat 5.5

2008-01-24 Thread Christopher Schultz

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Chuck,

Caldarale, Charles R wrote:
| From: Diogenes Gomes [mailto:[EMAIL PROTECTED]
| Subject: Re: Problem with protecting pages in Tomcat 5.5
|
| Please, do you know how to define any role?
|
| I don't believe the servlet spec allows for such a weak constraint.  You
| may want to consider using programmatic authentication (as defined in
| the servlet spec) rather than declarative.
|
| Take a look at:
| http://sourceforge.net/projects/securityfilter
|
| Although the last update was in 2004, it's recently become active again
| (thank you, Chris), and is much more flexible than what's allowed in the
| spec.

Yes, sf is a bit more flexible than Tomcat's built-in authentication and
authorization. sf currently interprets the * role to mean any
authenticated user, much like TC 5.0 (erroneously) did. Technically, we
should be checking against the list of defined roles, but we're not.

I expect this to be fixed in a future version, but we will probably
provide either a backward-compatibility setting to allow * to mean i
don't care at all or make it easy to re-implement the algorithm
yourself to get the same effect.

Diogenes, what's the problem with simply defining all of your roles in
the web.xml file?

- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkeY1Y0ACgkQ9CaO5/Lv0PCIDgCfe9KQT7St7Usf7qanEU8XGGFT
nDkAnjPSMAAZmzIQSaooClaGUZxybdFh
=kW3r
-END PGP SIGNATURE-

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



Re: Tomcat memory leak?

2008-01-24 Thread Martin Gainty
you need to modify web.xml to point to your jsp file e.g.
welcome-filesomething.jsp/welcome-file

we can help you with your action class ChangeConfig.jsp when you get around
sending us that class
attached is a picture of jconsole memory profiler run while loading and
init'ing something.jsp
notice the jump to 75% on the initial load but then settling to 30% after
the load which took no more than 1 second

Take a look at this article on non-multi-threaded python applications vs
Java Web applications performance tests
http://mrpointy.wordpress.com/2007/11/06/java-vs-python-performance/
conclusions are that unless you're doing ALOT of I/O (printing) or
Interpteter initialisation performance will increase significantly when
using Java over Python

Martin--
- Original Message -
From: Ofer Kalisky [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Thursday, January 24, 2008 10:31 AM
Subject: Re: Tomcat memory leak?


 That's what I'm saying, I've been sitting on this for two days and can't
 figure it out.
 Do you mean to say that you tried it and even when accessing the JSP with
 the script - your memory stays low? What am I doing wrong then?

 Please notice the tomcat version and the JRE version I stated (6.0.14,
 jre1.6.0_03).
 One more thing: as I said, I'm trying it with 64M of max heap space, but I
 figured, if it goes to 99.9% mem use, there's no use raising it (even
though
 I tried and it reached 99.9% after a short while)

 Ofer.

 - Original Message -
 From: Leon Rosenberg [EMAIL PROTECTED]
 To: Tomcat Users List users@tomcat.apache.org
 Sent: Thursday, January 24, 2008 5:25 PM
 Subject: Re: Tomcat memory leak?


 I downloaded your example.
  So you are telling us, that simply calling a JSP file with html markup
  only and without any code kills your tomcat?
 
  Regards
  Leon
 
  On Jan 24, 2008 4:19 PM, Ofer Kalisky [EMAIL PROTECTED] wrote:
  Ok, since sending an attachment doesn't work,
 
  simply create a webapp by the name of LoadTest and create two files
  inside:
  something.jsp and something.html
 
  the content of both files should be:
 
  htmlbody//html
 
 
  try the load.py with both:
 
  import httplib
 
  i = 0
  while 1:
   conn = httplib.HTTPConnection(localhost:8080)
   conn.request(GET, /LoadTest/something.jsp)
   r1 = conn.getresponse()
   if (i % 500 == 0):
print i
   i = i + 1
   conn.close()
 
  sorry for any inconvenience
 
  Ofer.
 
  - Original Message -
  From: Ofer Kalisky [EMAIL PROTECTED]
  To: Tomcat Users List users@tomcat.apache.org
 
  Sent: Thursday, January 24, 2008 5:08 PM
  Subject: Re: Tomcat memory leak?
 
 
  I think the mailing list blocks war files...
  
   trying with zip...
  
   - Original Message -
   From: [EMAIL PROTECTED]
   To: Tomcat Users List users@tomcat.apache.org
   Sent: Thursday, January 24, 2008 5:00 PM
   Subject: Re: Tomcat memory leak?
  
  
   Good Morning Ofer
  
   I dont see attachement of /LoadTest/something.jsp
  
   Martin-
- Original Message -
Wrom: FPEGAUTFJMVRESK
To: users@tomcat.apache.org
Sent: Thursday, January 24, 2008 9:51 AM
Subject: Tomcat memory leak?
  
  
Hi,
  
I know it's weird, but I'm doing the simplest thing and can't
believe
   there such a leak that I'm the first one to notice. I bet it's my
bad,
   please someone explain, what I'm doing wrong...
  
I created the simplest JSP and when I load test it - tomcat (6.0.14,
   jre1.6.0_03) goes to 99.9% memory use in a few minutes (If I raise
the
   max
   heap size it takes longer, but it happens several minutes
afterwards),
   and
   when I stop bombarding it, it doesn't return to the usual percentage.
  
When I try the same with an HTML instead of a JSP, that returns
   exactly
   the same - it stays on 12%-20%, cleans with the garbage collector,
and
   returns to the usual percentage (about 12%).
  
I tried profiling with several plugins and external programs, but I
   really
   can't understand what's going on. They tell me that most of the
   allocated
   bytes are char[], but I'm not sure who's the allocator and if
there's
   anything I can do about it...
  
Attached are:
1. a test in python that bombards the tomcat,
2. a war with both something.jsp and something.html (they are both
the
   same, but when I bombard something.html everything is ok, and when I
do
   the
   same for something.jsp - the problem occurs)
  
Can anyone tell me what I'm doing wrong? does it happen to you too?
  
Thanks, Ofer.
  
  
 
 --

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

 -
---
 
 
 
   

Advanced IO documentation in Tomcat 6 - Asynchronous writes

2008-01-24 Thread Alan Chaney
To help save someone else a bit of perplexity and confusion there 
appears to be a couple of slight errors in the Asynchronous writes 
section of the tomcat-6-0-doc/aio.html page.



 Any servlet can instruct Tomcat to perform a sendfile call by setting the 
appropriate response attributes. When using sendfile...




* org.apache.tomcat.sendfile.filename: Canonical filename of the file which 
will be sent as a String
* org.apache.tomcat.sendfile.start: Start offset as a Long
* org.apache.tomcat.sendfile.start: End offset as a Long



1. You actually set REQUEST attributes not response attributes (as of 
course there is no such thing as a response attribute)


2. The 3rd attribute is of course org.apache.tomcat.sendfile.end

However the actual code works just fine and thats probably the most 
important bit!


Regards

Alan

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



Re: Tomcat memory leak?

2008-01-24 Thread Christopher Schultz

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Ofer,

Ofer Kalisky wrote:
| That's what I'm saying, I've been sitting on this for two days and can't
| figure it out.

Does your JSP disable sessions? It's possible that your python script is
creating millions of (unused) sessions that don't expire before you bust
your heap.

- -chris

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkeY5k0ACgkQ9CaO5/Lv0PAW9ACeK3nEkRrl3t9gwhu91S28UmnO
aMYAoL824Fsk3pmuYWBPIORO54WqnuDG
=5J03
-END PGP SIGNATURE-

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



Re: Tomcat installation/deployment question

2008-01-24 Thread Martin Gainty
possibly better off with a server offering as specified in documentation
http://people.apache.org/~mturk/docs/article/ftwai.html
For non server products like Windows 2000 Professional or Windows XP the
number of concurrent connections is limited to 10. This mean that you can
not use workstation products for production servers unless the 10
connections limit will fulfil your needs. 

M-
- Original Message -
From: Sureka, Sushil [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Thursday, January 24, 2008 1:00 PM
Subject: RE: Tomcat installation/deployment question


XP but there is no guarantee that they won't go to Vista in a year
timeframe.

Sushil

 -Original Message-
 From: Gabe Wong [mailto:[EMAIL PROTECTED]
 Sent: Thursday, January 24, 2008 11:54 AM
 To: Tomcat Users List
 Subject: Re: Tomcat installation/deployment question

 Sureka, Sushil wrote:
 
  Hi,
 
  We are intending to deploy our application on
 individual laptops (to
  be used by field personnel who does not have internet
 connectivity to
  connect to our central server). The idea is that a trimmed down
  version of our core application will be deployed on
 individual laptops
  running tomcat against a light weight Sybase database.
 
  I wanted to see if you had any suggestions about -
  1. How best to deploy the initial version (5.5) of Tomcat on
  individual machines  - We understand our options are Microsoft SMS,
  Java Web Start application, shell script or Ant script to install
  Tomcat on these laptop boxes. We are leaning towards
 Microsoft SMS since
  (a) It can easily mass deploy the app to hundreds of machine
  (b) It is currently used in our organization to deploy some asp
  application.
  If you believe there are downsides to this approach or other
  approaches are better please let me know
 
  2. How best to deploy the upgraded version (6.x or higher) - We
  potentially could use the same approach as the first one,
 but wanted
  to see if the opinion differs.
 
  3. And finally the rollout of initial app and upgraded
 app version.
  Again probably use the same approach as before but wanted to throw
  this out there in case there are better ideas.
 
  Please let me know your thoughts on this.
 
  Sushil
 
 
 
 Sushil,

 The Laptops I presume will be running Windows? If so which version(s)?


 --
 Regards

 Gabe Wong
 NGASI AppServer Manager
 JAVA AUTOMATION and SaaS Enablement
 a href=http://www.ngasi.comhttp://www.ngasi.com/a
 NEW! 8.0 - Centrally manage multiple physical servers


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



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



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



RE: Tomcat installation/deployment question

2008-01-24 Thread Sureka, Sushil
Well we are not intending to use laptops to server multiple user. The
idea is that the user who is logged in on the laptop would just work
locally, when disconnected from network, and then we would synch  up the
database running on laptop with the central database.  

 -Original Message-
 From: Martin Gainty [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, January 24, 2008 1:31 PM
 To: Tomcat Users List
 Subject: Re: Tomcat installation/deployment question
 
 possibly better off with a server offering as specified in 
 documentation http://people.apache.org/~mturk/docs/article/ftwai.html
 For non server products like Windows 2000 Professional or 
 Windows XP the number of concurrent connections is limited to 
 10. This mean that you can not use workstation products for 
 production servers unless the 10 connections limit will 
 fulfil your needs. 
 
 M-
 - Original Message -
 From: Sureka, Sushil [EMAIL PROTECTED]
 To: Tomcat Users List users@tomcat.apache.org
 Sent: Thursday, January 24, 2008 1:00 PM
 Subject: RE: Tomcat installation/deployment question
 
 
 XP but there is no guarantee that they won't go to Vista in a 
 year timeframe.
 
 Sushil
 
  -Original Message-
  From: Gabe Wong [mailto:[EMAIL PROTECTED]
  Sent: Thursday, January 24, 2008 11:54 AM
  To: Tomcat Users List
  Subject: Re: Tomcat installation/deployment question
 
  Sureka, Sushil wrote:
  
   Hi,
  
   We are intending to deploy our application on
  individual laptops (to
   be used by field personnel who does not have internet
  connectivity to
   connect to our central server). The idea is that a trimmed down 
   version of our core application will be deployed on
  individual laptops
   running tomcat against a light weight Sybase database.
  
   I wanted to see if you had any suggestions about - 1. How best to 
   deploy the initial version (5.5) of Tomcat on individual 
 machines  - 
   We understand our options are Microsoft SMS, Java Web Start 
   application, shell script or Ant script to install Tomcat 
 on these 
   laptop boxes. We are leaning towards
  Microsoft SMS since
   (a) It can easily mass deploy the app to hundreds of machine
   (b) It is currently used in our organization to deploy some asp 
   application.
   If you believe there are downsides to this approach or other 
   approaches are better please let me know
  
   2. How best to deploy the upgraded version (6.x or higher) - We 
   potentially could use the same approach as the first one,
  but wanted
   to see if the opinion differs.
  
   3. And finally the rollout of initial app and upgraded
  app version.
   Again probably use the same approach as before but wanted 
 to throw 
   this out there in case there are better ideas.
  
   Please let me know your thoughts on this.
  
   Sushil
  
  
  
  Sushil,
 
  The Laptops I presume will be running Windows? If so which 
 version(s)?
 
 
  --
  Regards
 
  Gabe Wong
  NGASI AppServer Manager
  JAVA AUTOMATION and SaaS Enablement
  a href=http://www.ngasi.comhttp://www.ngasi.com/a
  NEW! 8.0 - Centrally manage multiple physical servers
 
 
  
 -
  To start a new topic, e-mail: users@tomcat.apache.org To 
 unsubscribe, 
  e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 -
 To start a new topic, e-mail: users@tomcat.apache.org To 
 unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 -
 To start a new topic, e-mail: users@tomcat.apache.org To 
 unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

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



Re: Tomcat installation/deployment question

2008-01-24 Thread David Brown
Hello Sushil, IMHO: ANT 1.7 has much improved deployment features in the area 
of remote distributed deployments.

Sureka, Sushil wrote ..
 
 
 
   Hi,

   We are intending to deploy our application on individual laptops
 (to be used by field personnel who does not have internet connectivity
 to connect to our central server). The idea is that a trimmed down
 version of our core application will be deployed on individual laptops
 running tomcat against a light weight Sybase database.

   I wanted to see if you had any suggestions about - 
   1. How best to deploy the initial version (5.5) of Tomcat on
 individual machines  - We understand our options are Microsoft SMS, Java
 Web Start application, shell script or Ant script to install Tomcat on
 these laptop boxes. We are leaning towards Microsoft SMS since 
   (a) It can easily mass deploy the app to hundreds of machine
   (b) It is currently used in our organization to deploy some asp
 application. 
   If you believe there are downsides to this approach or other
 approaches are better please let me know

   2. How best to deploy the upgraded version (6.x or higher) - We
 potentially could use the same approach as the first one, but wanted to
 see if the opinion differs.

   3. And finally the rollout of initial app and upgraded app
 version. Again probably use the same approach as before but wanted to
 throw this out there in case there are better ideas.

   Please let me know your thoughts on this.

   Sushil

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



Re: Tomcat installation/deployment question

2008-01-24 Thread Martin Gainty
you can install a server product (2003) on a laptop which has the requisite
chip characteristics/sufficient ram (4gb)/sufficient diskspace(.25 tera) and
sufficient clockspeed (in other words server hardware characteristics) to
support that server

Databases:
You can configure your connection-string to point to the remote DB server
and remote DBname which has a DBlistener installed e.g.

private static Driver c_Driver = null;
private static final String c_sDefaultDriverName =
oracle.jdbc.driver.OracleDriver,
private static final String  c_sDefaultDBURL =
jdbc:oracle:thin:@host:Port:DBName,

try {
c_Driver = (Driver)Class.forName(
c_sDriverName ).newInstance();
}
catch ( ClassNotFoundException cex )
{
}

//set your properties here and then connect with the provided URL
connection-string
   c_Driver.connect( c_sDBURL, props );


- Original Message -
From: Sureka, Sushil [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Thursday, January 24, 2008 2:39 PM
Subject: RE: Tomcat installation/deployment question


Well we are not intending to use laptops to server multiple user. The
idea is that the user who is logged in on the laptop would just work
locally, when disconnected from network, and then we would synch  up the
database running on laptop with the central database.

 -Original Message-
 From: Martin Gainty [mailto:[EMAIL PROTECTED]
 Sent: Thursday, January 24, 2008 1:31 PM
 To: Tomcat Users List
 Subject: Re: Tomcat installation/deployment question

 possibly better off with a server offering as specified in
 documentation http://people.apache.org/~mturk/docs/article/ftwai.html
 For non server products like Windows 2000 Professional or
 Windows XP the number of concurrent connections is limited to
 10. This mean that you can not use workstation products for
 production servers unless the 10 connections limit will
 fulfil your needs. 

 M-
 - Original Message -
 From: Sureka, Sushil [EMAIL PROTECTED]
 To: Tomcat Users List users@tomcat.apache.org
 Sent: Thursday, January 24, 2008 1:00 PM
 Subject: RE: Tomcat installation/deployment question


 XP but there is no guarantee that they won't go to Vista in a
 year timeframe.

 Sushil

  -Original Message-
  From: Gabe Wong [mailto:[EMAIL PROTECTED]
  Sent: Thursday, January 24, 2008 11:54 AM
  To: Tomcat Users List
  Subject: Re: Tomcat installation/deployment question
 
  Sureka, Sushil wrote:
  
   Hi,
  
   We are intending to deploy our application on
  individual laptops (to
   be used by field personnel who does not have internet
  connectivity to
   connect to our central server). The idea is that a trimmed down
   version of our core application will be deployed on
  individual laptops
   running tomcat against a light weight Sybase database.
  
   I wanted to see if you had any suggestions about - 1. How best to
   deploy the initial version (5.5) of Tomcat on individual
 machines  -
   We understand our options are Microsoft SMS, Java Web Start
   application, shell script or Ant script to install Tomcat
 on these
   laptop boxes. We are leaning towards
  Microsoft SMS since
   (a) It can easily mass deploy the app to hundreds of machine
   (b) It is currently used in our organization to deploy some asp
   application.
   If you believe there are downsides to this approach or other
   approaches are better please let me know
  
   2. How best to deploy the upgraded version (6.x or higher) - We
   potentially could use the same approach as the first one,
  but wanted
   to see if the opinion differs.
  
   3. And finally the rollout of initial app and upgraded
  app version.
   Again probably use the same approach as before but wanted
 to throw
   this out there in case there are better ideas.
  
   Please let me know your thoughts on this.
  
   Sushil
  
  
  
  Sushil,
 
  The Laptops I presume will be running Windows? If so which
 version(s)?
 
 
  --
  Regards
 
  Gabe Wong
  NGASI AppServer Manager
  JAVA AUTOMATION and SaaS Enablement
  a href=http://www.ngasi.comhttp://www.ngasi.com/a
  NEW! 8.0 - Centrally manage multiple physical servers
 
 
 
 -
  To start a new topic, e-mail: users@tomcat.apache.org To
 unsubscribe,
  e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 

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



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



-
To start a new 

RE: Tomcat installation/deployment question

2008-01-24 Thread Sureka, Sushil
Martin, thanks for the advise. We are already decided to move forward
with the decision to deploy on individual laptops. So yes we will have
sufficient hardware on laptop.

The question, what is the best way to put the tomcat installation and
upgrades, application installation and upgrades on the server. In other
words, question is not if, but how

Sushil

 -Original Message-
 From: Martin Gainty [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, January 24, 2008 2:21 PM
 To: Tomcat Users List
 Subject: Re: Tomcat installation/deployment question
 
 you can install a server product (2003) on a laptop which has 
 the requisite chip characteristics/sufficient ram 
 (4gb)/sufficient diskspace(.25 tera) and sufficient 
 clockspeed (in other words server hardware characteristics) 
 to support that server
 
 Databases:
 You can configure your connection-string to point to the 
 remote DB server and remote DBname which has a DBlistener 
 installed e.g.
 
 private static Driver c_Driver = null;
 private static final String c_sDefaultDriverName = 
 oracle.jdbc.driver.OracleDriver,
 private static final String  c_sDefaultDBURL = 
 jdbc:oracle:thin:@host:Port:DBName,
 
 try {
 c_Driver = (Driver)Class.forName( 
 c_sDriverName ).newInstance();
 }
 catch ( ClassNotFoundException cex )
 {
 }
 
 //set your properties here and then connect with the provided 
 URL connection-string
c_Driver.connect( c_sDBURL, props );
 
 
 - Original Message -
 From: Sureka, Sushil [EMAIL PROTECTED]
 To: Tomcat Users List users@tomcat.apache.org
 Sent: Thursday, January 24, 2008 2:39 PM
 Subject: RE: Tomcat installation/deployment question
 
 
 Well we are not intending to use laptops to server multiple 
 user. The idea is that the user who is logged in on the 
 laptop would just work locally, when disconnected from 
 network, and then we would synch  up the database running on 
 laptop with the central database.
 
  -Original Message-
  From: Martin Gainty [mailto:[EMAIL PROTECTED]
  Sent: Thursday, January 24, 2008 1:31 PM
  To: Tomcat Users List
  Subject: Re: Tomcat installation/deployment question
 
  possibly better off with a server offering as specified in 
  documentation 
 http://people.apache.org/~mturk/docs/article/ftwai.html
  For non server products like Windows 2000 Professional or 
 Windows XP 
  the number of concurrent connections is limited to 10. This 
 mean that 
  you can not use workstation products for production servers 
 unless the 
  10 connections limit will fulfil your needs. 
 
  M-
  - Original Message -
  From: Sureka, Sushil [EMAIL PROTECTED]
  To: Tomcat Users List users@tomcat.apache.org
  Sent: Thursday, January 24, 2008 1:00 PM
  Subject: RE: Tomcat installation/deployment question
 
 
  XP but there is no guarantee that they won't go to Vista in a year 
  timeframe.
 
  Sushil
 
   -Original Message-
   From: Gabe Wong [mailto:[EMAIL PROTECTED]
   Sent: Thursday, January 24, 2008 11:54 AM
   To: Tomcat Users List
   Subject: Re: Tomcat installation/deployment question
  
   Sureka, Sushil wrote:
   
Hi,
   
We are intending to deploy our application on
   individual laptops (to
be used by field personnel who does not have internet
   connectivity to
connect to our central server). The idea is that a trimmed down 
version of our core application will be deployed on
   individual laptops
running tomcat against a light weight Sybase database.
   
I wanted to see if you had any suggestions about - 1. 
 How best to 
deploy the initial version (5.5) of Tomcat on individual
  machines  -
We understand our options are Microsoft SMS, Java Web Start 
application, shell script or Ant script to install Tomcat
  on these
laptop boxes. We are leaning towards
   Microsoft SMS since
(a) It can easily mass deploy the app to hundreds of machine
(b) It is currently used in our organization to deploy some asp 
application.
If you believe there are downsides to this approach or other 
approaches are better please let me know
   
2. How best to deploy the upgraded version (6.x or higher) - We 
potentially could use the same approach as the first one,
   but wanted
to see if the opinion differs.
   
3. And finally the rollout of initial app and upgraded
   app version.
Again probably use the same approach as before but wanted
  to throw
this out there in case there are better ideas.
   
Please let me know your thoughts on this.
   
Sushil
   
   
   
   Sushil,
  
   The Laptops I presume will be running Windows? If so which
  version(s)?
  
  
   --
   Regards
  
   Gabe Wong
   NGASI AppServer Manager
   JAVA AUTOMATION and SaaS Enablement
   a href=http://www.ngasi.comhttp://www.ngasi.com/a
   NEW! 8.0 - Centrally manage multiple physical servers
  
  
  
  
 

Re: ConcurrentModificationException on tomcat cluster with SimpleTcpCluster strategy

2008-01-24 Thread Filip Hanik - Dev Lists

Christopher Schultz wrote:

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Filip,

Filip Hanik - Dev Lists wrote:
| no, its just common sense, given that the session should represent a
| client state,
| and by the time the cluster tries to serialize it, the request is over.

There's no guarantee that the request is complete before session changes
are replicated, is there? In that case, you can never manipulate any
collection you put into the session. If you want to change something,
you have to first remove it from the session, then change it, then put
it back.

In fact, you still are not covered, because removing the object from the
session merely removes the reference. If the session replicator is
running and copying, say, a Map to another machine in the cluster, you
can't even remove it from the session in order to modify it: you /must/
make a copy of it and work on the copy.

That's ridiculous IMHO.
read the source code and enlighten yourself instead of making 
assumptions and making comments like that.


| developers misuse sessions all the time, I would add this into that
| category.

Of course they do, but modifying a collection that's in the session
while the replicator just happens to be trying to serialize the session
is simply unreasonable to prevent.

| one can use a technology like terracotta that handles replication
| completely separate from the request flow, and at the field level.
| that technology doesn't suffer from the problem described above

I'm not sure it would... iterating over a collection (which I assume is
what the session replicator is doing) while another thread (a request)
is making legitimate changes to it would lead to a CME no matter what
replication technology is being used.
even terracotta is open source, read the source code there, and correct 
yourself


Filip


- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkeXsiMACgkQ9CaO5/Lv0PBfmgCcCFnKujLG269RQ+y/vqyPTBMB
sVQAn1z1mIrDf92g0UsFKeKgH/etyY3F
=MCCh
-END PGP SIGNATURE-

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






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



Re: ConcurrentModificationException on tomcat cluster with SimpleTcpClusterstrategy

2008-01-24 Thread Filip Hanik - Dev Lists

Caldarale, Charles R wrote:
From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED] 
Subject: Re: ConcurrentModificationException on tomcat 
cluster with SimpleTcpClusterstrategy


given that the session should represent a client state,
and by the time the cluster tries to serialize it, the 
request is over.



That ignores the situation where multiple requests from the same client
are being processed concurrently.  What are the conditions that provoke
replication (and therefore serialization)?  What mechanism is provided
for request processors to synchronize with the replicator?
  
that is correct, we thought of this scenario and decided that we 
wouldn't support it.
the problem with the scenario above is not only that the same client can 
have multiple requests, it can have multiple requests hitting different 
nodes in the cluster.
this would require implement distributed locking and there is no way of 
doing that without suffering too much of a performance degradation.


Filip


 - Chuck


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

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



  



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



Re: comet end event

2008-01-24 Thread Filip Hanik - Dev Lists


even with your code, I wasn't able to replicate what you were seeing.
what I would need to see what's going on for you:

1. a war file with your comet server, and source code
2. a test client
3. your server.xml

Filip

Peter Warren wrote:

Thanks, Filip, for your time on this!  I used your changes and still
get an END event.  With your changes the client and socket are
definitely staying alive now.  I stepped through the client code and
see the end event appear on the server as soon as I step through the
line that writes the 0crlfcrlf:

byte[] outputBytes = new String(0 + DELIMITER +
DELIMITER).getBytes(ENCODING);
--outputStream.write(outputBytes); // end event appears after this line

Anyway, I don't want to take up any more of your time on this.  I'm
using non-chunked httpurlconnections now, which are working fine for
me with comet.  I just wanted to let you know the behavior I'm seeing
on my machine.  It's possible there are problems with my test, but
you've got the code I'm using.  Maybe there's a configuration
difference on our tomcats?

If you want to pursue this further, let me know, and I'm happy to get
you any more information you need.  Otherwise, I appreciate your time
and thanks for all your work on tomcat!

Peter

On Jan 22, 2008 2:37 PM, Filip Hanik - Dev Lists [EMAIL PROTECTED] wrote:
  

your test client is wrong,I've pasted in the correct one

only three changes
1. set the timeout so that the socket stays alive
2. keep reading data so that the socket stays alive
3. 0crlfcrlf as the last chunk

works as expected. to make a workable client, it should read until it
gets the last-chunk, not read forever like I am doing. I just didn't see
the need to put in http parsing in the code to demonstrate it.

also, I applied the timeout patch that I wrote about earlier,so I am
setting the timeout in the comet servlet, without the patch its using
the connectionTimeout value

package test;

import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.net.NoRouteToHostException;
import java.net.Socket;
import java.net.URL;

public class TestClient {

private static final String ENCODING = ISO-8859-1;

private static final String DELIMITER = \r\n;

private URL url;

private InputStream inputStream;

private OutputStream outputStream;

private Socket socket;

public static void main(String[] args) throws Exception {
TestClient test = new TestClient();
test.test();
}

private void test() throws Exception {
url = new URL(http://localhost:8080/comet;);
initConnection();
sendHeaders();
send(comet test);
// uncomment sleep to get END event instead of read error
//try {
//Thread.sleep(50);
//} catch (InterruptedException ie) {
//// do nothing
//}
sendLastChunk();
// block on read to keep app alive - server never sends response
byte[] data = new byte[8192];
int result = inputStream.read(data);

while (result0) {
String s = new String(data,0,result);
System.out.println(Received data:\n+s);
result = inputStream.read(data);
}
{
System.out.println(Received EOF);
}
}

private void initConnection() throws IOException {
int port = url.getPort();
port = (port  0) ? url.getDefaultPort() : port;
try {
socket = new Socket(url.getHost(), port);
socket.setSoTimeout(Integer.MAX_VALUE);

socket.setKeepAlive(true);
inputStream = socket.getInputStream();
outputStream = socket.getOutputStream();
} catch (NoRouteToHostException nrthe) {
System.out.println(host:  + url.getHost());
nrthe.printStackTrace();
}
}

private void sendHeaders() throws IOException {
String path = url.getPath();
StringBuffer outputBuffer = new StringBuffer();
outputBuffer.append(POST  + path +  HTTP/1.1 + DELIMITER);
outputBuffer.append(Host:  + url.getHost() + DELIMITER);
outputBuffer.append(User-Agent: CometTest + DELIMITER);
outputBuffer.append(Connection: keep-alive + DELIMITER);
outputBuffer.append(Content-Type: text/plain + DELIMITER);
outputBuffer.append(Transfer-Encoding: chunked + DELIMITER);
outputBuffer.append(DELIMITER);
byte[] outputBytes = outputBuffer.toString().getBytes(ENCODING);
outputStream.write(outputBytes);
outputStream.flush();
}

private void send(String chunkData) throws IOException {
byte[] chunkBytes = chunkData.getBytes(ENCODING);
String hexChunkLength = Integer.toHexString(chunkBytes.length);
StringBuffer outputBuffer = new StringBuffer();
outputBuffer.append(hexChunkLength);
outputBuffer.append(DELIMITER);
outputBuffer.append(chunkData);

RE: ConcurrentModificationException on tomcat cluster with SimpleTcpClusterstrategy

2008-01-24 Thread Caldarale, Charles R
 From: Filip Hanik - Dev Lists [mailto:[EMAIL PROTECTED] 
 Subject: Re: ConcurrentModificationException on tomcat 
 cluster with SimpleTcpClusterstrategy
 
 that is correct, we thought of this scenario and decided that we 
 wouldn't support it.

Not unreasonable to avoid the performance hit for the 99% usual cases.

However, I'd still like to know what triggers the session replication
across the nodes of the cluster.  If it's some particular set of API
calls (e.g., closing the output stream), then it might be possible for
applications that need it to synchronize their own behavior with regards
to the session, and not run the risk of interfering with the
replication.

 - Chuck


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

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



Re: Server 2008 x64 + Java + Tomcat - does not work

2008-01-24 Thread Konstantin Kolinko
You should search through the list archives, e.g. at Nabble.com. In
this list there were several reports of successfully running Tomcat on
64-bit Windows during the last 6 months. Though that required some
manual configuration or tweaks.

Have a look at
1) 
http://www.nabble.com/Installing-Tomcat-on-Windows-Server-2003-x64-td10294769.html#a10301090

2)
http://www.nabble.com/Advice-about-Tomcat-on-x86_64-architecture..-td11500727.html#a13279694

I suggest you to
1) make sure that Java itself is running correctly for this OS and hardware,
2) start Tomcat from *.bat files (look into zip distributive, as those
are not included with exe installer) to make sure that it can run on
pure java,

If 1) or 2) fail, it is Java / OS / configuration issue.

3) only if steps 1) and 2) show correct results, proceed with
installing 64 bit versions of service executables, as suggested in
reply by Mark Thomas.

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



Re: find out the possible bottleneck webapp

2008-01-24 Thread Jonadan


maggie-41 wrote:
 
 But sometimes the response time of Tomcat is very long. At that time,
 the CPU usage is very high.
 
First of all, some of your application is causing this, you should be guess
which ones can cause. Otherwise, it could be followings;

1. Garbage collectors kicked in.
2. Compiling: both source and JIT.

If you don't have enough main memory, this will accomany with excessive
I/O as well as high CPU usage intemittantly mixed. Then you will have very
long resonse time.

If not, it could be your application.

Regards.


-- 
View this message in context: 
http://www.nabble.com/find-out-the-possible-bottleneck-webapp-tp15065234p15075430.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


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



Re: ConcurrentModificationException on tomcat cluster with SimpleTcpCluster strategy

2008-01-24 Thread Christopher Schultz

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Filip,

Filip Hanik - Dev Lists wrote:
| In fact, you still are not covered, because removing the object from the
| session merely removes the reference. If the session replicator is
| running and copying, say, a Map to another machine in the cluster, you
| can't even remove it from the session in order to modify it: you /must/
| make a copy of it and work on the copy.
|
| That's ridiculous IMHO.
|
| read the source code and enlighten yourself instead of making
| assumptions and making comments like that.

Thanks for the condescending attitude, dude. I appreciate it.

Which source code do you suggest?

| I'm not sure it would... iterating over a collection (which I assume is
| what the session replicator is doing) while another thread (a request)
| is making legitimate changes to it would lead to a CME no matter what
| replication technology is being used.
|
| even terracotta is open source, read the source code there, and correct
| yourself

I'm not interested in terracotta. I'm interested in how Tomcat reacts.
The OP said that it was blowing up. I'm positive it was his code doing
the concurrent modification of the Map. That's not the problem. From
your comments, it seems like you aren't allowed to modify any
collections in the session for fear of interfering with the replicator.

- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkeZCXIACgkQ9CaO5/Lv0PBYQQCePVmHM8SVwBLM2f1ALDdcSXaM
aucAnjgViqbZA0GnIpCuhYntUx9v2OTw
=kVv9
-END PGP SIGNATURE-

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



Too many open files exception under heavy load - need help!

2008-01-24 Thread Tobias Schulz-Hess
Hi there,

we use the current Tomcat 6.0 on 2 machines. The hardware is brand new and is 
really fast. We get lots of traffic which is usually handled well by the 
tomcats and the load on those machines is between 1 and 6 (when we have lots of 
traffic).
The machines have debian 4.1/64 as OS.

However, sometimes (especially if we have lots of traffic) we get the following 
exception:
INFO   | jvm 1| 2008/01/23 15:28:18 | java.net.SocketException: Too many 
open files
INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
java.net.PlainSocketImpl.socketAccept(Native Method)
INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
java.net.PlainSocketImpl.accept(PlainSocketImpl.java:384)
INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
java.net.ServerSocket.implAccept(ServerSocket.java:453)
INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
java.net.ServerSocket.accept(ServerSocket.java:421)
INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
org.apache.tomcat.util.net.DefaultServerSocketFactory.acceptSocket(DefaultServe
rSocketFactory.java:61)
INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
org.apache.tomcat.util.net.JIoEndpoint$Acceptor.run(JIoEndpoint.java:310)
INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
java.lang.Thread.run(Thread.java:619)
I

We already have altered the ulimit from 1024 (default) to 4096 (and therefore 
proofing: yes, I have used google and read almost everything about that 
exception).

We also looked into the open files and all 95% of them are from or to the 
Tomcat Port 8080. (The other 5% are open JARs, connections to memcached and 
MySQL and SSL-Socket).

Most of the connections to port 8080 are in the CLOSE_WAIT state.

I have the strong feeling that something (tomcat, JVM, whatsoever) relies that 
the JVM garbage collection will kill those open connections. However, if we 
have heavy load, the garbage collection is suspended and then the connections 
pile up. But this is just a guess.

How can this problem be solved?

Thank you and kind regards,

Tobias.

---
Tobias Schulz-Hess
 
ICS - Internet Consumer Services GmbH
Mittelweg 162
20148 Hamburg
 
Tel:+49 (0) 40 238 49 141
Fax:+49 (0) 40 415 457 14
E-Mail: [EMAIL PROTECTED]
Web:www.internetconsumerservices.com 

Projekte
www.dealjaeger.de 
www.verwandt.de

ICS Internet Consumer Services GmbH
Geschäftsführer: Dipl.-Kfm. Daniel Grözinger, Dipl.-Kfm. Sven Schmidt
Handelsregister: Amtsgericht Hamburg HRB 95149




Re: Too many open files exception under heavy load - need help!

2008-01-24 Thread Bruno Vilardo
Tobias,

You probably need to tune some kernel paramerters. I had some issues
with our application get stuck at some point that we needed to
restart everything. And since you said it is a brend new server, you
might have the defalt values set in there.

What Does uname -a say?

The kernel parameter controlling that changes from one UNIX flavor to
the next; generally it's named NFILES, MAXFILES or NINODE. I usually
tune these parameter for our Progress databases.
For Linux, this can be done dynamically by launching (fron the OS
prompt):

 echo 16384 /proc/sys/fs/file-max

Regards,

Bruno

On Jan 24, 2008 10:26 PM, Tobias Schulz-Hess
[EMAIL PROTECTED] wrote:
 Hi there,

 we use the current Tomcat 6.0 on 2 machines. The hardware is brand new and is 
 really fast. We get lots of traffic which is usually handled well by the 
 tomcats and the load on those machines is between 1 and 6 (when we have lots 
 of traffic).
 The machines have debian 4.1/64 as OS.

 However, sometimes (especially if we have lots of traffic) we get the 
 following exception:
 INFO   | jvm 1| 2008/01/23 15:28:18 | java.net.SocketException: Too many 
 open files
 INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
 java.net.PlainSocketImpl.socketAccept(Native Method)
 INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
 java.net.PlainSocketImpl.accept(PlainSocketImpl.java:384)
 INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
 java.net.ServerSocket.implAccept(ServerSocket.java:453)
 INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
 java.net.ServerSocket.accept(ServerSocket.java:421)
 INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
 org.apache.tomcat.util.net.DefaultServerSocketFactory.acceptSocket(DefaultServe
 rSocketFactory.java:61)
 INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
 org.apache.tomcat.util.net.JIoEndpoint$Acceptor.run(JIoEndpoint.java:310)
 INFO   | jvm 1| 2008/01/23 15:28:18 |   at 
 java.lang.Thread.run(Thread.java:619)
 I

 We already have altered the ulimit from 1024 (default) to 4096 (and therefore 
 proofing: yes, I have used google and read almost everything about that 
 exception).

 We also looked into the open files and all 95% of them are from or to the 
 Tomcat Port 8080. (The other 5% are open JARs, connections to memcached and 
 MySQL and SSL-Socket).

 Most of the connections to port 8080 are in the CLOSE_WAIT state.

 I have the strong feeling that something (tomcat, JVM, whatsoever) relies 
 that the JVM garbage collection will kill those open connections. However, if 
 we have heavy load, the garbage collection is suspended and then the 
 connections pile up. But this is just a guess.

 How can this problem be solved?

 Thank you and kind regards,

 Tobias.

 ---
 Tobias Schulz-Hess

 ICS - Internet Consumer Services GmbH
 Mittelweg 162
 20148 Hamburg

 Tel:+49 (0) 40 238 49 141
 Fax:+49 (0) 40 415 457 14
 E-Mail: [EMAIL PROTECTED]
 Web:www.internetconsumerservices.com

 Projekte
 www.dealjaeger.de
 www.verwandt.de

 ICS Internet Consumer Services GmbH
 Geschäftsführer: Dipl.-Kfm. Daniel Grözinger, Dipl.-Kfm. Sven Schmidt
 Handelsregister: Amtsgericht Hamburg HRB 95149




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



Re: Problem with protecting pages in Tomcat 5.5

2008-01-24 Thread Bill Barker

Diogenes Gomes [EMAIL PROTECTED] wrote in message 
news:[EMAIL PROTECTED]
 Thank you very much Caldarale.

 Please, do you know how to define any role? The framework I use
 takes care of authorization (based on service's methods). I only need
 to authenticate the user, otherwise I would double the access
 configuration.


There is a backwards compatible setting on the Realm /.  You add the 
attribute allRolesMode=authOnly, and Tomcat will revert to it's 5.0 
behavior.

 Diogenes

 2008/1/24, Caldarale, Charles R [EMAIL PROTECTED]:
  From: Diogenes Gomes [mailto:[EMAIL PROTECTED]
  Subject: Problem with protecting pages in Tomcat 5.5
 
auth-constraint
role-name*/role-name
/auth-constraint

 IIRC, 5.0 misinterpreted a role-name setting of *; this was corrected
 in 5.5 and above.  The asterisk does not mean any role, but rather
 all defined roles.  (See section 12 of the servlet spec.)  You need to
 provide a set of valid roles via security-role in your web.xml file.

  Context debug=99 docBase=${catalina.home}/webapps/testeweb
path=/testeweb

 Take out the docBase and path attributes - they're not allowed when the
 Context element is in META-INF/context.xml (where it should be).

  - Chuck


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

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



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

 




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



Error encountered : JNDI on Tomcat 5.5 for Database Informix with Informix JDBC driver

2008-01-24 Thread Amitava Chakraborty

Hi All,

I am from IBM - Informix Product Interoperability team .  I tried to
create a JNDI connection from Tomcat to Database Informix. But it is
throwing error. I classified the error by the following way :

1. When I tried with type=javax.sql.DataSource  , I am getting error
Cannot create PoolableConnectionFactory (Can't load driver
java.lang.reflect.InvocationTargetException) .

2. When I tried with  type=com.informix.jdbcx.IfxConnectionPoolDataSource
, I am getting error  java.sql.SQLException: No suitable driver.

3. But we use JNDI connections from WAS , WAS CE and Web Logic also. There
it works fine.

4. Here I have added a sample Java Code also for Pooled connection and it
is working fine.

So the clarification I need is,  whether Tomcat supports Informix for a
JNDI connection. If yes, please suggest me the way it should work . I
attached my context.xml as well as web.xml contains also.

Looking for your help eagerly.


Context File Entry:

  Resource name=jdbc/myinformix auth=Container
type=javax.sql.DataSource
   maxActive=100 maxIdle=30 maxWait=1
   username=inform password=inform123
driverClassName=com.informix.jdbc.IfxDriver

url=jdbc:informix-sqli://idcps2.in.ibm.com:16001/stores_demo:INFORMIXSERVER=ids1050/


WEB-INF\web.xml Entry:

descriptionInformix Test Connection/description
  resource-ref
  descriptionInformix DB Connection/description
  res-ref-namejdbc/myinformix/res-ref-name
  res-typejavax.sql.DataSource/res-type
  res-authContainer/res-auth
  /resource-ref

type Exception report

message

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

exception

org.apache.jasper.JasperException: Unable to get connection, DataSource
invalid: org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create
PoolableConnectionFactory (Can't load driver
java.lang.reflect.InvocationTargetException)

org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:460)

org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:355)

org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
  org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

root cause

javax.servlet.ServletException: Unable to get connection, DataSource
invalid: org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create
PoolableConnectionFactory (Can't load driver
java.lang.reflect.InvocationTargetException)

org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:841)

org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:774)

org.apache.jsp.Informix.test_005fconnection_jsp._jspService(test_005fconnection_jsp.java:80)
  org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)

org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
  org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

root cause

javax.servlet.jsp.JspException: Unable to get connection, DataSource
invalid: org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create
PoolableConnectionFactory (Can't load driver
java.lang.reflect.InvocationTargetException)

org.apache.taglibs.standard.tag.common.sql.QueryTagSupport.getConnection(Unknown
 Source)

org.apache.taglibs.standard.tag.common.sql.QueryTagSupport.doStartTag(Unknown
 Source)

org.apache.jsp.Informix.test_005fconnection_jsp._jspx_meth_sql_005fquery_005f0(test_005fconnection_jsp.java:99)

org.apache.jsp.Informix.test_005fconnection_jsp._jspService(test_005fconnection_jsp.java:57)
  org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)

org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
  org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:803)




===
Context File Entry:
Resource name=jdbc/myinformix auth=Container
type=com.informix.jdbcx.IfxConnectionPoolDataSource
   maxActive=100 maxIdle=30 maxWait=1
   username=inform password=inform123
driverClassName=com.informix.jdbc.IfxDriver

url=jdbc:informix-sqli://idcps2.in.ibm.com:16001/stores_demo:INFORMIXSERVER=ids1050/

WEB-INF\web.xml Entry:

resource-ref
  descriptionInformix DB Connection/description
  

Re: Error encountered : JNDI on Tomcat 5.5 for Database Informix with Informix JDBC driver

2008-01-24 Thread Gabe Wong

Amitava Chakraborty wrote:

Hi All,

I am from IBM - Informix Product Interoperability team .  I tried to
create a JNDI connection from Tomcat to Database Informix. But it is
throwing error. I classified the error by the following way :

1. When I tried with type=javax.sql.DataSource  , I am getting error
Cannot create PoolableConnectionFactory (Can't load driver
java.lang.reflect.InvocationTargetException) .

2. When I tried with  type=com.informix.jdbcx.IfxConnectionPoolDataSource
, I am getting error  java.sql.SQLException: No suitable driver.

3. But we use JNDI connections from WAS , WAS CE and Web Logic also. There
it works fine.
  


You need to add the driver under ./common/lib/
More info can be found here:
http://marc.info/?l=tomcat-userw=2r=1s=No+suitable+driverq=b

--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


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



Re: Error encountered : JNDI on Tomcat 5.5 for Database Informix with Informix JDBC driver

2008-01-24 Thread Amitava Chakraborty
Gabe,

Informix JDBC jars (ifxjdbc.jar , ifxjdbcx.jar) are already there under
./common/lib/

Thanks..
Amitava Chakraborty  PMP®
Lead - Informix Interoperability
IBM India PVT LTD.
Plot No 12, Block - G, 2nd Floor ,
The Mira Corporation Suites, Old Ishwar Nagar,
Mathura Rd.   New Delhi 110065
---
Ph : Extn : 91-11-46592644 / 91-129-4033409
Mobile : +919958995870
Fax : 91-11-26921061
E - id : [EMAIL PROTECTED]


   
 Gabe Wong 
 [EMAIL PROTECTED] 
 omTo
   Tomcat Users List   
 25/01/2008 11:13  users@tomcat.apache.org   
cc
   
 Please respond to Subject
   Tomcat Users   Re: Error encountered : JNDI on 
   List   Tomcat 5.5 for Database Informix
 [EMAIL PROTECTED] with Informix JDBC driver   
 che.org  
   
   
   
   
   




Amitava Chakraborty wrote:
 Hi All,

 I am from IBM - Informix Product Interoperability team .  I tried to
 create a JNDI connection from Tomcat to Database Informix. But it is
 throwing error. I classified the error by the following way :

 1. When I tried with type=javax.sql.DataSource  , I am getting error
 Cannot create PoolableConnectionFactory (Can't load driver
 java.lang.reflect.InvocationTargetException) .

 2. When I tried with
type=com.informix.jdbcx.IfxConnectionPoolDataSource
 , I am getting error  java.sql.SQLException: No suitable driver.

 3. But we use JNDI connections from WAS , WAS CE and Web Logic also.
There
 it works fine.


You need to add the driver under ./common/lib/
More info can be found here:
http://marc.info/?l=tomcat-userw=2r=1s=No+suitable+driverq=b

--
Regards

Gabe Wong
NGASI AppServer Manager
JAVA AUTOMATION and SaaS Enablement
a href=http://www.ngasi.comhttp://www.ngasi.com/a
NEW! 8.0 - Centrally manage multiple physical servers


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




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