Problems with Backup Manager

2010-11-22 Thread Josef Pullicino
Hi all,

 

We are trying to setup session replication using tomcat as webserver. We
have two nodes communicating together via multicast address groups using
asynchronous communication channel. As an underlying platform, we are using
liferay portal. 

 

We are having problems using Backup Manager especially when deploying hot
portlets. The attached error (Backup Error.txt) is being produced. A lot of
research has been carried out but we did not find any reasonable solution. 

 

You can also find a copy of our server.xml file in which all settings
related to tomcat are found there.

 

Any help would be greatly appreciated.

 

Regards,

 

Josef Pullicino

Systems Administrator

GO

 

GO, Fra Diego Street, Marsa, MRS 1501, Malta.

t  +356 2594 6827 f  +356 2124 0112

w www.go.com.mt

 

This email and any files or content transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they are
addressed. This message contains confidential information and is intended
only for the individual named. If you are not the named addressee you should
not disseminate, distribute or copy this e-mail. Please notify the sender
immediately by e-mail if you have received this e-mail by mistake and delete
this e-mail from your system. If you are not the intended recipient you are
notified that disclosing, copying, distributing or taking any action in
reliance on the contents of this information is strictly prohibited. The
Company and the originator of this email accept no liability for the content
of this email, or for the consequences of any actions taken on the basis of
the information provided, unless that information is subsequently confirmed
in writing. If you are not the intended recipient you are notified that
disclosing, copying, distributing or taking any action in reliance on the
contents of this information is strictly prohibited.


Warning: Although the Company and the originator  have taken reasonable
precautions to ensure no viruses are present in this email, the company
cannot accept responsibility for any loss or damage arising from the use of
this email or attachments.

Nov 22, 2010 11:42:02 AM org.apache.catalina.ha.session.BackupManager start
SEVERE: Unable to start BackupManager
java.lang.NullPointerException
at 
org.apache.catalina.ha.session.BackupManager.start(BackupManager.java:195)
at 
org.apache.catalina.core.StandardContext.start(StandardContext.java:4351)
at 
org.apache.catalina.startup.HostConfig.checkResources(HostConfig.java:1116)
at org.apache.catalina.startup.HostConfig.check(HostConfig.java:1214)
at 
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:293)
at 
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at 
org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1337)
at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1601)
at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1590)
at java.lang.Thread.run(Thread.java:619)
Nov 22, 2010 11:42:02 AM org.apache.catalina.core.StandardContext start
SEVERE: Error manager.start()
LifecycleException:  Failed to start BackupManager:  
java.lang.NullPointerException
at 
org.apache.catalina.ha.session.BackupManager.start(BackupManager.java:208)
at 
org.apache.catalina.core.StandardContext.start(StandardContext.java:4351)
at 
org.apache.catalina.startup.HostConfig.checkResources(HostConfig.java:1116)
at org.apache.catalina.startup.HostConfig.check(HostConfig.java:1214)
at 
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:293)
at 
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at 
org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1337)
at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1601)
at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1590)
at java.lang.Thread.run(Thread.java:619)
Nov 22, 2010 11:42:02 AM org.apache.catalina.core.StandardContext start
SEVERE: Context [/go-portal-login-theme] startup failed due to previous errors?xml version='1.0' encoding='utf-8'?
!--
  Licensed to the Apache Software Foundation (ASF) under one or more
  contributor license agreements.  See the NOTICE file distributed with
  this work for additional information regarding copyright ownership.
  The ASF licenses this file to You under the Apache License, 

Error uploading a large file with slow connection

2010-11-22 Thread Odilo Schwade Junior
Hi list,

We are using tomcat with Railo to use CFML and getting an strange issue..

When we try to upload a file of 2~4MB on a slow connection 15~20kb/s the
request is completed but all of the form fields are dropped.. which causes
an error..

How to reproduce the error with a small CFM code:

// form_upload.cfm
form name=form1 action=upload.cfm method=post
enctype=multipart/form-data
  File: input type=file name=fileData
  input type=submit
/form

//upload.cfm
cfsetting requesttimeout=36000 /

cffile
action=upload
filefield=form.fileData
destination=#application.tempDir#
nameconflict=makeunique /

cfdump var=#cffile#

This only happens with large files and/or slow connection.


Here is some information about the test environment:
- Railo 3.2.0.001 rc
- OS Linux (2.6.18-164.15.1.el5) = CentOS 5.4
- Servlet Container Apache Tomcat/6.0.20 and also tested with Apache
Tomcat/6.0.29

the tomcat configuration doesn't has many changes, and it seems not have any
change that would affect this behavior.

tomcat's server.xml
Connector port=8080 protocol=HTTP/1.1
connectionTimeout=2
redirectPort=8443 /

tomcat's web.xml (timeout=30 minutes)
session-config
session-timeout30/session-timeout
/session-config

apache-tomcat workers.properties
type=ajp13
socket_timeout=300

So what is important to notice:

1) socket_timeout just kill inactive connections, in other words,
connections with 5 minutes without any activity.
The error occurs even for upload minor that 5 minutes (socket_timeout)
and longer than 50 seconds (Railo's default request timeout), like a 2
minutes upload.

2) anyway, we commented this parameter (to infinity) and the same error
occurred

3) We create a simple simple CFM file that just (a) sleep a couple of
seconds and (b) print a Ticket Count and it ran for more than one hour, user
cfsetting requesttimeout=36000

This test runs fine, that makes me deduce the issue occurs only when I
have a cffile action=upload in the template
In other words: A normal CFM request runs for so long, fine. An upload,
not.

4) Backing to upload issue: I's important to note the request finishes
perfectly.
In other words: Railo continues processing this request after the
upload.

The problem is, in that case, the form scope/variables is empty and
Railo raises an error saying form field [form.my_upload_field] is not a
file field

We also put a cfdump var=#form# before the cffile tag, it outputs
empty.
In other words: Any form field is sent.

5) This issue only occurs for long uploads.
If I execute the same upload, for the same file, in a fast connection,
it works fine.

The error only occurs on slow connections and larger files.
Once slow connections is so common in Brazil, we can't upload larger
files, and I mean as larger files, files with a few MegaBytes of size.

To reproduce this issues you'll need to simulate a slower connections.
Some thing like 5-10KB/s (64-128 bit/s).
In many cases it's normal in Brazil, specially when accessing
international sites or sites hosted abroad.

You can do it using the Firefox Add-on Firefox Throttle
(Download 
herehttp://www.uselessapplications.com/en/Application/FirefoxThrottle.aspx?src=0%3Affthrottle%3Aoptions
).
Set a 10 KB/s link and upload a file with size of 3-5 Mb.

Our Railo default timeout (Railo Web Admin - Application - Request
timeout) is set to 50 seconds
and you can use a cfsetting requesttimeout=3600 (1 hour) in your
CFML code for that upload test.

6) It seems the error only occurs for cffile action=upload for slower
connections.
Import to note that the request is processed by Railo.

I can even process other CFML codes before the cffile action=upload
tag.

It seems that some internal procedure is subjected default request
timeout.
In other words: It seems some internal procedure/function is NOT
following the cfsetting requesttimout parameter.


The stacktrace:

form field [form.fileData] is not a file field
at railo.runtime.tag.FileTag.getFormItem(FileTag.java:833):833
at railo.runtime.tag.FileTag.actionUpload(FileTag.java:666):666
at railo.runtime.tag.FileTag.doStartTag(FileTag.java:299):299
at admin.tools.upload_cfm$cf.call(/wwwroot/app/admin/tools/upload.cfm:7):7
at railo.runtime.PageContextImpl.doInclude(PageContextImpl.java:763):763
at
railo.runtime.listener.ModernAppListener._onRequest(ModernAppListener.java:199):199
at
railo.runtime.listener.MixedAppListener.onRequest(MixedAppListener.java:23):23
at railo.runtime.PageContextImpl.execute(PageContextImpl.java:1972):1972
at
railo.runtime.engine.CFMLEngineImpl.serviceCFML(CFMLEngineImpl.java:280):280
at railo.loader.servlet.CFMLServlet.service(CFMLServlet.java:32):32
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717):717
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290):290
at

RE: Problems with Backup Manager

2010-11-22 Thread Caldarale, Charles R
 From: Josef Pullicino [mailto:josef.pullic...@go.com.mt] 
 Subject: Problems with Backup Manager

 We are having problems using Backup Manager especially 
 when deploying hot portlets.

Care to give us a hint about the version of Tomcat you're using, the JVM it's 
running on, the platform that's running in, whether or not you're using APR, 
and how the two Tomcat's are connected?  (Same machine, private LAN, or ???)

What's in the Context element for the webapp(s) of interest?  Do you have 
distributable set in the webapp's WEB-INF/web.xml file or Context element?

 - Chuck


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


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Problems with Backup Manager

2010-11-22 Thread Mark Thomas
On 22/11/2010 14:35, Caldarale, Charles R wrote:
 From: Josef Pullicino [mailto:josef.pullic...@go.com.mt] 
 Subject: Problems with Backup Manager
 
 We are having problems using Backup Manager especially 
 when deploying hot portlets.
 
 Care to give us a hint about the version of Tomcat you're using, the JVM it's 
 running on, the platform that's running in, whether or not you're using APR, 
 and how the two Tomcat's are connected?  (Same machine, private LAN, or ???)
 
 What's in the Context element for the webapp(s) of interest?  Do you have 
 distributable set in the webapp's WEB-INF/web.xml file or Context element?

The root cause of these issues looks like a faulty listener.

quote
SEVERE: Context [/go-portal-login-theme] startup failed due to previous
errors
/quote

The stack trace for that will be in the logs.

Mark

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Problems with Backup Manager

2010-11-22 Thread Mark Thomas
On 22/11/2010 14:38, Mark Thomas wrote:
 On 22/11/2010 14:35, Caldarale, Charles R wrote:
 From: Josef Pullicino [mailto:josef.pullic...@go.com.mt] 
 Subject: Problems with Backup Manager

 We are having problems using Backup Manager especially 
 when deploying hot portlets.

 Care to give us a hint about the version of Tomcat you're using, the JVM 
 it's running on, the platform that's running in, whether or not you're using 
 APR, and how the two Tomcat's are connected?  (Same machine, private LAN, or 
 ???)

 What's in the Context element for the webapp(s) of interest?  Do you have 
 distributable set in the webapp's WEB-INF/web.xml file or Context 
 element?
 
 The root cause of these issues looks like a faulty listener.

Ignore the above - I was reading too quickly.

 quote
 SEVERE: Context [/go-portal-login-theme] startup failed due to previous
 errors
 /quote
 
 The stack trace for that will be in the logs.

There is however, likely to be be some useful information earlier in the
logs.

mark

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: Problems with Backup Manager

2010-11-22 Thread Josef Pullicino
Hi Chuck,

Thanks for your reply.

Details as follows:

Tomcat version: 6.0.18
JVM:1.6.0_21
OS: Red Hat Enterprise Linux Server release 5.5
(Tikanga)

Tomcats are on different machines with the same OS. They are connected with
multicast address group, this being 239.0.0.1.

I have included Context distributable=true into tomcat's context.xml.

Thanks,
Josef

-Original Message-
From: Caldarale, Charles R [mailto:chuck.caldar...@unisys.com] 
Sent: 22 November 2010 15:36
To: Tomcat Users List
Subject: RE: Problems with Backup Manager

 From: Josef Pullicino [mailto:josef.pullic...@go.com.mt]
 Subject: Problems with Backup Manager

 We are having problems using Backup Manager especially when deploying 
 hot portlets.

Care to give us a hint about the version of Tomcat you're using, the JVM
it's running on, the platform that's running in, whether or not you're using
APR, and how the two Tomcat's are connected?  (Same machine, private LAN, or
???)

What's in the Context element for the webapp(s) of interest?  Do you have
distributable set in the webapp's WEB-INF/web.xml file or Context
element?

 - Chuck


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


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



smime.p7s
Description: S/MIME cryptographic signature


Re: Several hosts within one tomcat / catch-all problem

2010-11-22 Thread Konstantin Kolinko
2010/11/21 David Fisher dfis...@jmlafferty.com:
 and use JMX or call mapper.addHostAlias(..) directly to add aliases
 programmatically at runtime.  (though there is no guarantee that the
 Mapper API does not change between Tomcat minor releases).

 I investigated what an implementation of this might look like at a higher 
 level. In looking through the Tomcat interfaces it looks like this is similar 
 to the notion of automatically creating Context for users with a UserConfig 
 listener.

 It would be an AliasConfig class extending HostConfig.
  Listener className=my.web.server.listener.package.AliasConfig 
 aliases=/path/to/alias/file/

 Then in the start event function it is as simple as 
 host.addAlias(subDomainName); for each alias found in the aliases file.

 Does this make sense?


It does make sense.

o.a.c.connector.MapperListener updates the mapper when the aliases
list in the Host is changed.

Best regards,
Konstantin Kolinko

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Error uploading a large file with slow connection

2010-11-22 Thread Pid
On 22/11/2010 11:20, Odilo Schwade Junior wrote:
 The stacktrace:
 
 form field [form.fileData] is not a file field
 at railo.runtime.tag.FileTag.getFormItem(FileTag.java:833):833
 at railo.runtime.tag.FileTag.actionUpload(FileTag.java:666):666
 at railo.runtime.tag.FileTag.doStartTag(FileTag.java:299):299
 at admin.tools.upload_cfm$cf.call(/wwwroot/app/admin/tools/upload.cfm:7):7
 at railo.runtime.PageContextImpl.doInclude(PageContextImpl.java:763):763
 at


Seems pretty clear to me.  It's failing when it detects one of the other
form fields.  You need to handle that in your code.


p


0x62590808.asc
Description: application/pgp-keys


signature.asc
Description: OpenPGP digital signature


Re: Deployment issues

2010-11-22 Thread Victor Kabdebon
Hi everybody,

After having check the log files, several things appear :

22 nov. 2010 18:02:30 org.apache.catalina.startup.HostConfig deployWAR
INFO: Déploiement de l'archive ..war de l'application web
java.io.FileNotFoundException: /opt/victor/tomcat-base/webapps/ROOT.war
(Permission denied)

The second line translation is :
INFO : deploying archive ..war of web application

Where does this error come from ?

Secondly, I have noticed that if I try to delete the ROOT.war in webapps and
I try to deploy my index.war at the location / a ROOT.war appears with the
exact same size that the index.war, so I imagine that my war
is successfully copied.
I tried to access the / of my server and I saw the following error :
 :
java.io.FileNotFoundException:
/opt/victor/tomcat-base/work/Catalina/localhost/manager/ROOT.war (No such
file or directory)

I checked and indeed this file is not in the directory. Is it supposed to be
there to be deployed ?

I am really lost on this issue I don't understand what is its problem...


Thank you for your help
Victor


2010/11/20 Konstantin Kolinko knst.koli...@gmail.com

 2010/11/21 Victor Kabdebon victor.kabde...@gmail.com:
  Hiello Konstantin
 
  Yes I do have access to the HTML manager interface, but nothing is
 deployed
  in the list.
  I will check the context file in conf/catalina/localhost, I don't have
  access to it right now, I didn't think about it.
 
  Thank you very much for your help. Is there anything else that I might
 have
  missed ?
 

 The log files? There might be something interesting there.

 Also I should say that error handling during deploy and undeploy
 operations was improved in 6.0.24. See CVE-2009-2901
 http://tomcat.apache.org/security-6.html

 Best regards,
 Konstantin Kolinko

 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org




[SECURITY] CVE-2010-4172: Apache Tomcat Manager application XSS vulnerability

2010-11-22 Thread Mark Thomas
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

CVE-2010-4172: Apache Tomcat Manager application XSS vulnerability

Severity: Tomcat 7.0.x - Low, Tomcat 6.0.x - Moderate

Vendor: The Apache Software Foundation

Versions Affected:
- - Tomcat 7.0.0 to 7.0.4
  - Not affected in default configuration.
  - Affected if CSRF protection is disabled
  - Additional XSS issues if web applications are untrusted
- - Tomcat 6.0.12 to 6.0.29
  - Affected in default configuration
  - Additional XSS issues if web applications are untrusted
- - Tomcat 5.5.x
  - Not affected

Description:
The session list screen (provided by sessionList.jsp) in affected
versions uses the orderBy and sort request parameters without applying
filtering and therefore is vulnerable to a cross-site scripting attack.
Users should be aware that Tomcat 6 does not use httpOnly for session
cookies by default so this vulnerability could expose session cookies
from the manager application to an attacker.
A review of the Manager application by the Apache Tomcat security team
identified additional XSS vulnerabilities if the web applications
deployed were not trusted.

Example:
GET
/manager/html/sessions?path=/sort=scriptalert('xss')/scriptorder=ASCaction=injectSessionsrefresh=Refresh+Sessions+list

Mitigation:
Users of affected versions should apply one of the following mitigations
- - Tomcat 7.0.0 to 7.0.4
  - Remove the Manager application
  - Remove the sessionList.jsp and sessionDetail.jsp files
  - Ensure the CSRF protection is enabled
  - Apply the patch 7.0.4 patch (see below)
  - Update to 7.0.5 when released
- - Tomcat 6.0.12 to 6.0.29
  - Remove the Manager application
  - Remove the sessionList.jsp and sessionDetail.jsp files
  - Apply the patch for 6.0.29 (see below)
  - Update to 6.0.30 when released

No release date has been set for the next Tomcat 7.0.x and Tomcat 6.0.x
releases.

Credit:
The original issue was discovered by Adam Muntner of Gotham Digital Science.
Additional issues were identified by the Tomcat security team as a
result of reviewing the original issue.

References:
http://tomcat.apache.org/security.html
http://tomcat.apache.org/security-7.html
http://tomcat.apache.org/security-6.html

Note: The patches The Apache Tomcat Security Team



Patch for 6.0.29


Index: webapps/manager/WEB-INF/jsp/sessionDetail.jsp
===
- --- webapps/manager/WEB-INF/jsp/sessionDetail.jsp (revision 1037769)
+++ webapps/manager/WEB-INF/jsp/sessionDetail.jsp   (working copy)
@@ -30,8 +30,10 @@
 % String path = (String) request.getAttribute(path);
Session currentSession =
(Session)request.getAttribute(currentSession);
HttpSession currentHttpSession = currentSession.getSession();
- -   String currentSessionId = currentSession.getId();
- -   String submitUrl =
((HttpServletRequest)pageContext.getRequest()).getRequestURL().toString();
+   String currentSessionId = JspHelper.escapeXml(currentSession.getId());
+   String submitUrl = JspHelper.escapeXml(
+   ((HttpServletRequest)
pageContext.getRequest()).getRequestURI() +
+   ?path= + path);
 %
 head
 meta http-equiv=content-type content=text/html;
charset=iso-8859-1/
@@ -45,7 +47,7 @@
titleSessions Administration: details for %= currentSessionId
%/title
 /head
 body
- -h1Details for Session %= JspHelper.escapeXml(currentSessionId) %/h1
+h1Details for Session %= currentSessionId %/h1
  table style=text-align: left; border=0
   tr
@@ -54,7 +56,7 @@
   /tr
   tr
 thGuessed Locale/th
- -td%= JspHelper.guessDisplayLocaleFromSession(currentSession)
%/td
+td%=
JspHelper.escapeXml(JspHelper.guessDisplayLocaleFromSession(currentSession))
%/td
   /tr
   tr
 thGuessed User/th
@@ -120,7 +122,7 @@
String attributeName = (String)
attributeNamesEnumeration.nextElement();
 %
tr
- - td align=centerform action=%= submitUrl 
%divinput
type=hidden name=path value=%= path % /input type=hidden
name=action value=removeSessionAttribute /input type=hidden
name=sessionId value=%= currentSessionId % /input type=hidden
name=attributeName value=%= attributeName % /input type=submit
value=Remove //div/form/td
+   td align=centerform action=%= submitUrl 
%divinput
type=hidden name=action value=removeSessionAttribute /input
type=hidden name=sessionId value=%= currentSessionId % /input
type=hidden name=attributeName value=%=
JspHelper.escapeXml(attributeName) % /input type=submit
value=Remove //div/form/td
td%= JspHelper.escapeXml(attributeName) %/td
td% Object attributeValue =
currentHttpSession.getAttribute(attributeName); %span title=%=
attributeValue == null ?  : attributeValue.getClass().toString()
%%= JspHelper.escapeXml(attributeValue) %/span/td
/tr
Index: webapps/manager/WEB-INF/jsp/sessionsList.jsp

[ANN] New Tomcat committer: Christopher Schultz (schultz)

2010-11-22 Thread Mark Thomas
On behalf of the Tomcat committers I am pleased to announce that
Christopher Schultz (schultz) has been voted in as a new Tomcat committer.

Please join me in welcoming him.

Mark

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: [ANN] New Tomcat committer: Christopher Schultz (schultz)

2010-11-22 Thread Propes, Barry L
Congrats, Chris!!


-Original Message-
From: Mark Thomas [mailto:ma...@apache.org]
Sent: Monday, November 22, 2010 1:17 PM
To: Tomcat Users List; Tomcat Developers List
Subject: [ANN] New Tomcat committer: Christopher Schultz (schultz)

On behalf of the Tomcat committers I am pleased to announce that Christopher 
Schultz (schultz) has been voted in as a new Tomcat committer.

Please join me in welcoming him.

Mark

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: [ANN] New Tomcat committer: Christopher Schultz (schultz)

2010-11-22 Thread Héctor Gómez

He is the man!
Congrats!!

 From: barry.l.pro...@citi.com
 To: users@tomcat.apache.org; d...@tomcat.apache.org
 Date: Mon, 22 Nov 2010 14:19:43 -0600
 Subject: RE: [ANN] New Tomcat committer: Christopher Schultz (schultz)
 
 Congrats, Chris!!
 
 
 -Original Message-
 From: Mark Thomas [mailto:ma...@apache.org]
 Sent: Monday, November 22, 2010 1:17 PM
 To: Tomcat Users List; Tomcat Developers List
 Subject: [ANN] New Tomcat committer: Christopher Schultz (schultz)
 
 On behalf of the Tomcat committers I am pleased to announce that Christopher 
 Schultz (schultz) has been voted in as a new Tomcat committer.
 
 Please join me in welcoming him.
 
 Mark
 
 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org
 
  
-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: [ANN] New Tomcat committer: Christopher Schultz (schultz)

2010-11-22 Thread Pid
On 22/11/2010 19:16, Mark Thomas wrote:
 On behalf of the Tomcat committers I am pleased to announce that
 Christopher Schultz (schultz) has been voted in as a new Tomcat committer.
 
 Please join me in welcoming him.

Nice.  Welcome Chris!


p

 Mark
 
 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org
 



0x62590808.asc
Description: application/pgp-keys


signature.asc
Description: OpenPGP digital signature


Re: [ANN] New Tomcat committer: Christopher Schultz (schultz)

2010-11-22 Thread André Warnier

Mark Thomas wrote:

On behalf of the Tomcat committers I am pleased to announce that
Christopher Schultz (schultz) has been voted in as a new Tomcat committer.

Please join me in welcoming him.


Wälcöme Chris.
He the man.



-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: [ANN] New Tomcat committer: Christopher Schultz (schultz)

2010-11-22 Thread Leon Rosenberg
grats chris! :-)

On Mon, Nov 22, 2010 at 9:48 PM, André Warnier a...@ice-sa.com wrote:
 Mark Thomas wrote:

 On behalf of the Tomcat committers I am pleased to announce that
 Christopher Schultz (schultz) has been voted in as a new Tomcat committer.

 Please join me in welcoming him.

 Wälcöme Chris.
 He the man.



 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org



-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: [ANN] New Tomcat committer: Christopher Schultz (schultz)

2010-11-22 Thread Caldarale, Charles R
 On behalf of the Tomcat committers I am pleased to announce that
 Christopher Schultz (schultz) has been voted in as a new Tomcat committer.

 Please join me in welcoming him.

And you thought you were busy before...

Congratulations.

 - Chuck


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


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Server affinity instead of session affinity

2010-11-22 Thread Andrew Hole
Hi guys!

There is any available configuration to define server affinity instead of
session affinity? Our architecture setup is based on multiple JVMs (tomcat)
instances in each server (machine). The goal is to send all requests (within
a session) from a client browser to the same machine. Is it possible to
perform it using jvmRoute?

Thanks a lot


RE: Server affinity instead of session affinity

2010-11-22 Thread Caldarale, Charles R
 From: Andrew Hole [mailto:andremailingl...@gmail.com] 
 Subject: Server affinity instead of session affinity

 The goal is to send all requests (within a session) from a 
 client browser to the same machine. Is it possible to
 perform it using jvmRoute?

Can't you just set the jvmRoute value for each Tomcat on the same box to the 
same value?  That would presume you're doing something to share sessions across 
all of the Tomcats running on one box.

 - Chuck

P.S.  Don't cross-post.


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


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Server affinity instead of session affinity

2010-11-22 Thread André Warnier

Andrew Hole wrote:

Hi guys!

There is any available configuration to define server affinity instead of
session affinity? Our architecture setup is based on multiple JVMs (tomcat)
instances in each server (machine). The goal is to send all requests (within
a session) from a client browser to the same machine. Is it possible to
perform it using jvmRoute?


I am not sure I understand the question correctly, but if I do, that's what it 
does, no ?
Does sending to the same Tomcat not imply sending to the same machine ?



-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: [ANN] New Tomcat committer: Christopher Schultz (schultz)

2010-11-22 Thread Konstantin Kolinko
2010/11/22 Mark Thomas ma...@apache.org:
 On behalf of the Tomcat committers I am pleased to announce that
 Christopher Schultz (schultz) has been voted in as a new Tomcat committer.


Welcome!

Best regards,
Konstantin Kolinko

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: [ANN] New Tomcat committer: Christopher Schultz (schultz)

2010-11-22 Thread Wesley Acheson
Congratulations.

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Server affinity instead of session affinity

2010-11-22 Thread Andrew Hole
No... Session affinity (jvmRoute in JSESSION ID) implies sending to the same
tomcat instance (same JVM), not for the same machine.

Some idea?


On Mon, Nov 22, 2010 at 9:10 PM, André Warnier a...@ice-sa.com wrote:

 Andrew Hole wrote:

 Hi guys!

 There is any available configuration to define server affinity instead of
 session affinity? Our architecture setup is based on multiple JVMs
 (tomcat)
 instances in each server (machine). The goal is to send all requests
 (within
 a session) from a client browser to the same machine. Is it possible to
 perform it using jvmRoute?

  I am not sure I understand the question correctly, but if I do, that's
 what it does, no ?
 Does sending to the same Tomcat not imply sending to the same machine ?




 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org




Re: users Digest 22 Nov 2010 20:46:42 -0000 Issue 10094

2010-11-22 Thread Nicholas Sushkin
On Monday, November 22, 2010 15:46:42 users-digest-h...@tomcat.apache.org 
wrote:
 On behalf of the Tomcat committers I am pleased to announce that
 Christopher Schultz (schultz) has been voted in as a new Tomcat committer.
 
 Please join me in welcoming him.
 
 Mark

Do you mean he wasn't?! Oh, I should've ignored all his posts! ;)
-- 
Nicholas Sushkin


smime.p7s
Description: S/MIME cryptographic signature


Re: Server affinity instead of session affinity

2010-11-22 Thread André Warnier

Andrew Hole wrote:

No... Session affinity (jvmRoute in JSESSION ID) implies sending to the same
tomcat instance (same JVM), not for the same machine.


I guess that I still don't get it.
The same Tomcat instance /is/, per definition, on the same machine.

Or do you want to send the request to a /different/ Tomcat instance, but only one which is 
on the same machine ? And if yes, why would you want to do that ?


In other words, why would you /not/ want to send the request to the same Tomcat on the 
same machine ?




-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Server affinity instead of session affinity

2010-11-22 Thread Andrew Hole
An example:
Machine 1:
Tomcat A

Tomcat B

On Mon, Nov 22, 2010 at 11:05 PM, André Warnier a...@ice-sa.com wrote:

 Andrew Hole wrote:

 No... Session affinity (jvmRoute in JSESSION ID) implies sending to the
 same
 tomcat instance (same JVM), not for the same machine.

  I guess that I still don't get it.
 The same Tomcat instance /is/, per definition, on the same machine.

 Or do you want to send the request to a /different/ Tomcat instance, but
 only one which is on the same machine ? And if yes, why would you want to do
 that ?

 In other words, why would you /not/ want to send the request to the same
 Tomcat on the same machine ?




 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org




Re: Server affinity instead of session affinity

2010-11-22 Thread Andrew Hole
Sorry for the inconvenience. I sent the email with wrong content.

An example:
Machine 1:
Tomcat A
  App1
  App2
Tomcat B
  App3
  App4

Machine 2:
Tomcat C
  App1
  App2
Tomcat D
  App3
  App4

Using session affinity, if I make a request to App1 and the Tomcat A in
Machine 1 is selected. All the sequent requests will be redirected (within
the same session) to the same Tomcat (tomcat A). However, if i make a
request to App3, Tomcat B (machine 1) or Tomcat D (machine 2) could be
selected. What I really want is that the request to App3 could be done to
Tomcat B in machine 1 (the request was done using the same browser client).

Thanks


On Mon, Nov 22, 2010 at 11:23 PM, Andrew Hole andremailingl...@gmail.comwrote:

 An example:
 Machine 1:
 Tomcat A

 Tomcat B


 On Mon, Nov 22, 2010 at 11:05 PM, André Warnier a...@ice-sa.com wrote:

 Andrew Hole wrote:

 No... Session affinity (jvmRoute in JSESSION ID) implies sending to the
 same
 tomcat instance (same JVM), not for the same machine.

  I guess that I still don't get it.
 The same Tomcat instance /is/, per definition, on the same machine.

 Or do you want to send the request to a /different/ Tomcat instance, but
 only one which is on the same machine ? And if yes, why would you want to do
 that ?

 In other words, why would you /not/ want to send the request to the same
 Tomcat on the same machine ?




 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org





Re: Server affinity instead of session affinity

2010-11-22 Thread André Warnier

Andrew Hole wrote:

Sorry for the inconvenience. I sent the email with wrong content.

An example:
Machine 1:
Tomcat A
  App1
  App2
Tomcat B
  App3
  App4

Machine 2:
Tomcat C
  App1
  App2
Tomcat D
  App3
  App4

Using session affinity, if I make a request to App1 and the Tomcat A in
Machine 1 is selected. All the sequent requests will be redirected (within
the same session) to the same Tomcat (tomcat A). However, if i make a
request to App3, Tomcat B (machine 1) or Tomcat D (machine 2) could be
selected. What I really want is that the request to App3 could be done to
Tomcat B in machine 1 (the request was done using the same browser client).


Ok, now I get it.
My next question is : why ?
Why is it important that, having started on Tomcat A with App1, the same client would get 
App3 on Tomcat B, rather than on Tomcat D ?

What do Tomcat A and Tomcat B have in common, that Tomcat C and D don't ?
And vice-versa.

And , should your scheme still work if in the future, Tomcat A and Tomcat B were split 
onto two separate machines ?


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Server affinity instead of session affinity

2010-11-22 Thread Andrew Hole
There is a middleware-to-middleware connection between Tomcat A and Tomcat B
using RMI (point-to-point protocol) and Tomcat A has in-memory data useful
to App3.
The same aproach in the second server: applications in tomcat d have RMI
communication to tomcat c.

thanks

On Mon, Nov 22, 2010 at 11:58 PM, André Warnier a...@ice-sa.com wrote:

 Andrew Hole wrote:

 Sorry for the inconvenience. I sent the email with wrong content.

 An example:
 Machine 1:
 Tomcat A
  App1
  App2
 Tomcat B
  App3
  App4

 Machine 2:
 Tomcat C
  App1
  App2
 Tomcat D
  App3
  App4

 Using session affinity, if I make a request to App1 and the Tomcat A in
 Machine 1 is selected. All the sequent requests will be redirected (within
 the same session) to the same Tomcat (tomcat A). However, if i make a
 request to App3, Tomcat B (machine 1) or Tomcat D (machine 2) could be
 selected. What I really want is that the request to App3 could be done to
 Tomcat B in machine 1 (the request was done using the same browser
 client).

  Ok, now I get it.
 My next question is : why ?
 Why is it important that, having started on Tomcat A with App1, the same
 client would get App3 on Tomcat B, rather than on Tomcat D ?
 What do Tomcat A and Tomcat B have in common, that Tomcat C and D don't ?
 And vice-versa.

 And , should your scheme still work if in the future, Tomcat A and Tomcat B
 were split onto two separate machines ?


 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org




Re: [ANN] New Tomcat committer: Christopher Schultz (schultz)

2010-11-22 Thread Hassan Schroeder
On Mon, Nov 22, 2010 at 11:16 AM, Mark Thomas ma...@apache.org wrote:
 On behalf of the Tomcat committers I am pleased to announce that
 Christopher Schultz (schultz) has been voted in as a new Tomcat committer.

 Please join me in welcoming him.

Major props to Chris :-)

-- 
Hassan Schroeder  hassan.schroe...@gmail.com
twitter: @hassan

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



mod-jk not called after PerlHandler gets called

2010-11-22 Thread Mohit Anchlia
I posted this thread in mod_perl group:

http://www.gossamer-threads.com/lists/modperl/modperl/102273

I thought I should ask here as well. I have a perl handler in VirtualHost:

JkMount /bridge/* tc

PerlModule Apache2::Rules2
SetHandler modperl
PerlInitHandler Apache2::Rules2
PerlSendHeader On

This Handler just returns DECLINED. After this handler is called the
apache web server tries to find the document on the web server instead
of forwarding it to JkMount ... nod-jk worker. I get 404 and in
the access logs of apache I see that it's trying to locate the
document on the same server instead of using JkMount to forward the
request to mod-jk.

How can I make this work? There is nothing online on this topic.

Rules2.pm

package Apache2::Rules2;
#use lib '/home/.mohit/mod_perl-2.0.4/lib';
use strict;
use warnings;
use Apache2::Const qw(:common);
use Apache2::RequestRec ();
use Apache2::RequestIO ();
sub handler {
my $r = shift;
#$r-content_type('text/plain');
#$r-print(mod_perl rules!\n);
return DECLINED; # We must return a status to mod_perl
}
1; # This is a perl module so we must return true to perl
~

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



clearThreadLocalMap and NullPointerException

2010-11-22 Thread Blair Zajac
With Tomcat 6.0.29 and Java 6u22, when I'm stopping Tomcat I'm getting 
the attached log, which at the end is a NullPointerException thrown from 
AbstractCollection#toString() which is called from clearThreadLocalMap().


java.lang.NullPointerException
at java.util.AbstractCollection.toString(AbstractCollection.java:415)
	at 
org.apache.catalina.loader.WebappClassLoader.clearThreadLocalMap(WebappClassLoader.java:2379)
	at 
org.apache.catalina.loader.WebappClassLoader.clearReferencesThreadLocals(WebappClassLoader.java:2304)
	at 
org.apache.catalina.loader.WebappClassLoader.clearReferences(WebappClassLoader.java:1886)
	at 
org.apache.catalina.loader.WebappClassLoader.stop(WebappClassLoader.java:1798)


Unfortunately, I can't tell what the key or value is due to this.

The web application does a GC when it unloads ZeroC's Ice runtime to 
ensure that all objects that implement #finialize() are properly 
finalized, otherwise I get even more exceptions.  This is seen in Java's 
GC stats in the log.


Any suggestions in tracking this down?  Would a custom Tomcat build that 
gets each key and value in a try/catch block be useful?


Regards,
Blair
Nov 22, 2010 5:49:06 PM org.apache.coyote.http11.Http11Protocol pause
INFO: Pausing Coyote HTTP/1.1 on http-8080
Nov 22, 2010 5:49:07 PM org.apache.catalina.core.StandardService stop
INFO: Stopping service Catalina
Nov 22, 2010 5:49:07 PM org.apache.catalina.core.ApplicationContext log
INFO: Closing Spring root WebApplicationContext
37.480: [GC [PSYoungGen: 1057265K-9094K(7340032K)] 
1058825K-10654K(15728640K), 0.0128710 secs] [Times: user=0.06 sys=0.00, 
real=0.01 secs] 
37.493: [Full GC (System) [PSYoungGen: 9094K-0K(7340032K)] [ParOldGen: 
1560K-10200K(8388608K)] 10654K-10200K(15728640K) [PSPermGen: 
45121K-45016K(85184K)], 0.2334650 secs] [Times: user=0.50 sys=0.01, real=0.23 
secs] 
Nov 22, 2010 5:49:12 PM org.apache.catalina.loader.WebappClassLoader 
clearReferencesThreads
SEVERE: The web application [/foobar] appears to have started a thread named 
[com.google.common.base.internal.Finalizer] but has failed to stop it. This is 
very likely to create a memory leak.
Nov 22, 2010 5:49:12 PM org.apache.catalina.loader.WebappClassLoader 
clearReferencesThreads
SEVERE: The web application [/foobar] appears to have started a thread named 
[com.google.common.base.internal.Finalizer] but has failed to stop it. This is 
very likely to create a memory leak.
Nov 22, 2010 5:49:12 PM org.apache.catalina.loader.WebappClassLoader 
clearReferencesThreads
SEVERE: The web application [/foobar] appears to have started a thread named 
[Timer-1] but has failed to stop it. This is very likely to create a memory 
leak.
Nov 22, 2010 5:49:12 PM org.apache.catalina.loader.WebappClassLoader 
clearReferencesThreads
SEVERE: The web application [/foobar] appears to have started a thread named 
[Thread-21] but has failed to stop it. This is very likely to create a memory 
leak.
Nov 22, 2010 5:49:12 PM org.apache.catalina.loader.WebappClassLoader 
clearThreadLocalMap
SEVERE: The web application [/foobar] created a ThreadLocal with key of type 
[com.sun.jna.Native$3] (value [com.sun.jna.nativ...@6197cc]) and a value of 
type [java.lang.Integer] (value [2]) but failed to remove it when the web 
application was stopped. This is very likely to create a memory leak.
Nov 22, 2010 5:49:12 PM org.apache.catalina.loader.WebappClassLoader 
clearThreadLocalMap
SEVERE: The web application [/foobar] created a ThreadLocal with key of type 
[com.sun.jna.Structure$1] (value [com.sun.jna.structur...@734d246]) and a value 
of type [java.util.HashMap] (value [{}]) but failed to remove it when the web 
application was stopped. This is very likely to create a memory leak.
Nov 22, 2010 5:49:12 PM org.apache.catalina.startup.HostConfig undeployApps
WARNING: Error while removing context [/foobar]
java.lang.NullPointerException
at java.util.AbstractCollection.toString(AbstractCollection.java:415)
at 
org.apache.catalina.loader.WebappClassLoader.clearThreadLocalMap(WebappClassLoader.java:2379)
at 
org.apache.catalina.loader.WebappClassLoader.clearReferencesThreadLocals(WebappClassLoader.java:2304)
at 
org.apache.catalina.loader.WebappClassLoader.clearReferences(WebappClassLoader.java:1886)
at 
org.apache.catalina.loader.WebappClassLoader.stop(WebappClassLoader.java:1798)
at org.apache.catalina.loader.WebappLoader.stop(WebappLoader.java:738)
at 
org.apache.catalina.core.StandardContext.stop(StandardContext.java:4812)
at 
org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java:924)
at 
org.apache.catalina.startup.HostConfig.undeployApps(HostConfig.java:1319)
at org.apache.catalina.startup.HostConfig.stop(HostConfig.java:1290)
at 
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:323)
at 
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at 

Re: users Digest 22 Nov 2010 20:46:42 -0000 Issue 10094

2010-11-22 Thread Bill Barker



Nicholas Sushkin nsush...@openfinance.com wrote in message 
news:201011221714.26614.nsush...@openfinance.com...

On Monday, November 22, 2010 15:46:42 users-digest-h...@tomcat.apache.org
wrote:

On behalf of the Tomcat committers I am pleased to announce that
Christopher Schultz (schultz) has been voted in as a new Tomcat 
committer.


Please join me in welcoming him.

Mark


Do you mean he wasn't?! Oh, I should've ignored all his posts! ;)


That is the thing about Open Source.  Anyone can download the code and look 
through it, learn it, and answer questions/supply patches.  When we get 
tired of applying your patches, we say do it yourself, and elect to 
committer ;).

--
Nicholas Sushkin




-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: OutOfMemoryError some time on some tomcat!!!!1

2010-11-22 Thread Daniel Baktiar
hi xu cheng,

having a powerful machine with big memory is good. but don't assume that
everything will be used automatically.
the jvm doesn't automatically use all the resources in your memory when you
start tomcat. you need to configure it.
try to add something like this:
*CATALINA_OPTS=-XX:MaxPermSize=512m *
inside your catalina.sh (linux/unix) or catalina.bat (windows).
you can put this as the first line (after the comments, for example).

try to run again and see whether you still have the same error(s).

PermGen space is the permanent generational heap for storing data such as
class data. you will bump into this when deploying a large application or
deploying repetitively. you will still get the exception when deploying
often, only less frequent.
---
daniel baktiar
http://savinggaia.tritiumapps.com - saving the planet is everyone's
business!




2010/11/22 xu cheng xcheng@gmail.com

 after tracing the app with jprofiler for several hours , I still cannot
 figure the problem.
 it seems that the app doesn't use  a lot of memory.
 and it still run pretty well in my computer.and after it is deployed in the
 server, it crash
 the problem of the environment? but the tomcat on the server has been
 running for a really long time with out any problem
 what's the point?.oh no   (°ο°)

 2010/11/22 xu cheng xcheng@gmail.com

  by the way,
  it doesn't throws this exception while running on my computer
  it is only when the app is deploy on another computer that this problem
  occur
 
  2010/11/22 xu cheng xcheng@gmail.com
 
  hi:
  thanks for replying
  the app is running on a powerful server and the memory is suppose to be
  enough
  I'll check if there is a memory leak,(althouth the app is suppose to use
  only a few memory)
  thanks
 
  2010/11/22 Caldarale, Charles R chuck.caldar...@unisys.com
 
   From: xu cheng [mailto:xcheng@gmail.com]
   Subject: OutOfMemoryError some time on some tomcat1
 
   the app works pretty well on my pc, and the tomcat
   is apache-tomcat-6.0.29
   however , when I put this app on to another computer
   with the same tomcat it throws this exception
   Java HotSpot(TM) 64-Bit Server VM warning: Exception
   java.lang.OutOfMemoryError
 
   Exception in thread http-8080-24
   java.lang.OutOfMemoryError: PermGen space
 
  64-bit JVMs often require larger heap sizes than 32-bit ones.  If the
  error occurs on the first deployment of the app, you may just need to
  configure a larger PermGen.  However, if this error occurs only after
  redeploying your app some number of times, you likely have a memory
 leak.
   Use any of the widely available profilers or heap analysis tools to
 see
  just what is consuming memory.  You can get some pointers here:
 
  http://wiki.apache.org/tomcat/FAQ/Memory
 
   - Chuck
 
 
  THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE
 PROPRIETARY
  MATERIAL and is thus for use only by the intended recipient. If you
 received
  this in error, please contact the sender and delete the e-mail and its
  attachments from all computers.
 
 
  -
  To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
  For additional commands, e-mail: users-h...@tomcat.apache.org
 
 
 
 



Re: OutOfMemoryError some time on some tomcat!!!!1

2010-11-22 Thread xu cheng
hi Daniel
thanks alot for replying.

I don't know how to figure out how much the param MaxPermSize is set to. may
be it's set to be default. I just set the xmx and xms, so I thought that the
memory will absolutely enough, I didn't
notice this param, my fault.

I did an experiment on tomcat , I just kept redeploying apps , and the perm
gen keep growing each time I deploy the same app. and when I undeploy the
app, the perm gen didn't clean the garbage
( I think they are garbage, but I don't know whether the vm can figure it
out, I monitor this with the
jconsole in the jdk/bin). in the meanwhile , the code cache in the memory
pool and the loaded classes grow with the same curve like the permanent
generation. the unused class meta data wasn't cleaned up during each
deployment.

I always redeploy the  apps with shutting down the server, I think that
might be the point.

by the way , this aritical help me a lot to understand it.
http://blogs.sun.com/jonthecollector/entry/presenting_the_permanent_generation

thanks again for helping

2010/11/23 Daniel Baktiar dbakt...@gmail.com

 hi xu cheng,

 having a powerful machine with big memory is good. but don't assume that
 everything will be used automatically.
 the jvm doesn't automatically use all the resources in your memory when you
 start tomcat. you need to configure it.
 try to add something like this:
 *CATALINA_OPTS=-XX:MaxPermSize=512m *
 inside your catalina.sh (linux/unix) or catalina.bat (windows).
 you can put this as the first line (after the comments, for example).

 try to run again and see whether you still have the same error(s).

 PermGen space is the permanent generational heap for storing data such as
 class data. you will bump into this when deploying a large application or
 deploying repetitively. you will still get the exception when deploying
 often, only less frequent.
 ---
 daniel baktiar
 http://savinggaia.tritiumapps.com - saving the planet is everyone's
 business!




 2010/11/22 xu cheng xcheng@gmail.com

  after tracing the app with jprofiler for several hours , I still cannot
  figure the problem.
  it seems that the app doesn't use  a lot of memory.
  and it still run pretty well in my computer.and after it is deployed in
 the
  server, it crash
  the problem of the environment? but the tomcat on the server has been
  running for a really long time with out any problem
  what's the point?.oh no   (°ο°)
 
  2010/11/22 xu cheng xcheng@gmail.com
 
   by the way,
   it doesn't throws this exception while running on my computer
   it is only when the app is deploy on another computer that this problem
   occur
  
   2010/11/22 xu cheng xcheng@gmail.com
  
   hi:
   thanks for replying
   the app is running on a powerful server and the memory is suppose to
 be
   enough
   I'll check if there is a memory leak,(althouth the app is suppose to
 use
   only a few memory)
   thanks
  
   2010/11/22 Caldarale, Charles R chuck.caldar...@unisys.com
  
From: xu cheng [mailto:xcheng@gmail.com]
Subject: OutOfMemoryError some time on some tomcat1
  
the app works pretty well on my pc, and the tomcat
is apache-tomcat-6.0.29
however , when I put this app on to another computer
with the same tomcat it throws this exception
Java HotSpot(TM) 64-Bit Server VM warning: Exception
java.lang.OutOfMemoryError
  
Exception in thread http-8080-24
java.lang.OutOfMemoryError: PermGen space
  
   64-bit JVMs often require larger heap sizes than 32-bit ones.  If the
   error occurs on the first deployment of the app, you may just need to
   configure a larger PermGen.  However, if this error occurs only after
   redeploying your app some number of times, you likely have a memory
  leak.
Use any of the widely available profilers or heap analysis tools to
  see
   just what is consuming memory.  You can get some pointers here:
  
   http://wiki.apache.org/tomcat/FAQ/Memory
  
- Chuck
  
  
   THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE
  PROPRIETARY
   MATERIAL and is thus for use only by the intended recipient. If you
  received
   this in error, please contact the sender and delete the e-mail and
 its
   attachments from all computers.
  
  
   -
   To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
   For additional commands, e-mail: users-h...@tomcat.apache.org
  
  
  
  
 



Re: OutOfMemoryError some time on some tomcat!!!!1

2010-11-22 Thread xu cheng
ps:
after several times of redeployment,
java.lang.OutOfMemoryError: PermGen space comes up.
I always redeploy the  apps *without* shutting down the server

在 2010年11月23日 下午1:50,xu cheng xcheng@gmail.com写道:

 hi Daniel
 thanks alot for replying.

 I don't know how to figure out how much the param MaxPermSize is set to.
 may be it's set to be default. I just set the xmx and xms, so I thought that
 the memory will absolutely enough, I didn't
 notice this param, my fault.

 I did an experiment on tomcat , I just kept redeploying apps , and the perm
 gen keep growing each time I deploy the same app. and when I undeploy the
 app, the perm gen didn't clean the garbage
 ( I think they are garbage, but I don't know whether the vm can figure it
 out, I monitor this with the
 jconsole in the jdk/bin). in the meanwhile , the code cache in the memory
 pool and the loaded classes grow with the same curve like the permanent
 generation. the unused class meta data wasn't cleaned up during each
 deployment.

 I always redeploy the  apps with shutting down the server, I think that
 might be the point.

 by the way , this aritical help me a lot to understand it.

 http://blogs.sun.com/jonthecollector/entry/presenting_the_permanent_generation

 thanks again for helping

 2010/11/23 Daniel Baktiar dbakt...@gmail.com

 hi xu cheng,

 having a powerful machine with big memory is good. but don't assume that
 everything will be used automatically.
 the jvm doesn't automatically use all the resources in your memory when
 you
 start tomcat. you need to configure it.
 try to add something like this:
 *CATALINA_OPTS=-XX:MaxPermSize=512m *
 inside your catalina.sh (linux/unix) or catalina.bat (windows).
 you can put this as the first line (after the comments, for example).

 try to run again and see whether you still have the same error(s).

 PermGen space is the permanent generational heap for storing data such as
 class data. you will bump into this when deploying a large application or
 deploying repetitively. you will still get the exception when deploying
 often, only less frequent.
 ---
 daniel baktiar
 http://savinggaia.tritiumapps.com - saving the planet is everyone's
 business!




 2010/11/22 xu cheng xcheng@gmail.com

  after tracing the app with jprofiler for several hours , I still cannot
  figure the problem.
  it seems that the app doesn't use  a lot of memory.
  and it still run pretty well in my computer.and after it is deployed in
 the
  server, it crash
  the problem of the environment? but the tomcat on the server has been
  running for a really long time with out any problem
  what's the point?.oh no   (°ο°)
 
  2010/11/22 xu cheng xcheng@gmail.com
 
   by the way,
   it doesn't throws this exception while running on my computer
   it is only when the app is deploy on another computer that this
 problem
   occur
  
   2010/11/22 xu cheng xcheng@gmail.com
  
   hi:
   thanks for replying
   the app is running on a powerful server and the memory is suppose to
 be
   enough
   I'll check if there is a memory leak,(althouth the app is suppose to
 use
   only a few memory)
   thanks
  
   2010/11/22 Caldarale, Charles R chuck.caldar...@unisys.com
  
From: xu cheng [mailto:xcheng@gmail.com]
Subject: OutOfMemoryError some time on some tomcat1
  
the app works pretty well on my pc, and the tomcat
is apache-tomcat-6.0.29
however , when I put this app on to another computer
with the same tomcat it throws this exception
Java HotSpot(TM) 64-Bit Server VM warning: Exception
java.lang.OutOfMemoryError
  
Exception in thread http-8080-24
java.lang.OutOfMemoryError: PermGen space
  
   64-bit JVMs often require larger heap sizes than 32-bit ones.  If
 the
   error occurs on the first deployment of the app, you may just need
 to
   configure a larger PermGen.  However, if this error occurs only
 after
   redeploying your app some number of times, you likely have a memory
  leak.
Use any of the widely available profilers or heap analysis tools to
  see
   just what is consuming memory.  You can get some pointers here:
  
   http://wiki.apache.org/tomcat/FAQ/Memory
  
- Chuck
  
  
   THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE
  PROPRIETARY
   MATERIAL and is thus for use only by the intended recipient. If you
  received
   this in error, please contact the sender and delete the e-mail and
 its
   attachments from all computers.
  
  
  
 -
   To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
   For additional commands, e-mail: users-h...@tomcat.apache.org
  
  
  
  
 





Re: OutOfMemoryError some time on some tomcat!!!!1

2010-11-22 Thread Daniel Baktiar
hi xu cheng,

don't mention it.
glad you've eventually solved your problem.

daniel

---
daniel baktiar
http://savinggaia.tritiumapps.com - saving the planet is everyone's
business!




2010/11/23 xu cheng xcheng@gmail.com

 hi Daniel
 thanks alot for replying.

 I don't know how to figure out how much the param MaxPermSize is set to.
 may be it's set to be default. I just set the xmx and xms, so I thought that
 the memory will absolutely enough, I didn't
 notice this param, my fault.

 I did an experiment on tomcat , I just kept redeploying apps , and the perm
 gen keep growing each time I deploy the same app. and when I undeploy the
 app, the perm gen didn't clean the garbage
 ( I think they are garbage, but I don't know whether the vm can figure it
 out, I monitor this with the
 jconsole in the jdk/bin). in the meanwhile , the code cache in the memory
 pool and the loaded classes grow with the same curve like the permanent
 generation. the unused class meta data wasn't cleaned up during each
 deployment.

 I always redeploy the  apps with shutting down the server, I think that
 might be the point.

 by the way , this aritical help me a lot to understand it.

 http://blogs.sun.com/jonthecollector/entry/presenting_the_permanent_generation

 thanks again for helping

 2010/11/23 Daniel Baktiar dbakt...@gmail.com

 hi xu cheng,

 having a powerful machine with big memory is good. but don't assume that
 everything will be used automatically.
 the jvm doesn't automatically use all the resources in your memory when
 you
 start tomcat. you need to configure it.
 try to add something like this:
 *CATALINA_OPTS=-XX:MaxPermSize=512m *
 inside your catalina.sh (linux/unix) or catalina.bat (windows).
 you can put this as the first line (after the comments, for example).

 try to run again and see whether you still have the same error(s).

 PermGen space is the permanent generational heap for storing data such as
 class data. you will bump into this when deploying a large application or
 deploying repetitively. you will still get the exception when deploying
 often, only less frequent.
 ---
 daniel baktiar
 http://savinggaia.tritiumapps.com - saving the planet is everyone's
 business!








RE: OutOfMemoryError some time on some tomcat!!!!1

2010-11-22 Thread Caldarale, Charles R
 From: xu cheng [mailto:xcheng@gmail.com] 
 Subject: Re: OutOfMemoryError some time on some tomcat1

 I just kept redeploying apps , and the perm gen keep 
 growing each time I deploy the same app. and when I 
 undeploy the app, the perm gen didn't clean the garbage

Exactly the situation I suggested the other day: you have something that's 
hanging onto a reference to an object from your webapp classes, preventing the 
old webapp deployment from being garbage collected.  Again, read this:

http://wiki.apache.org/tomcat/FAQ/Memory

Also, take a look at these:

http://blogs.sun.com/fkieviet/entry/classloader_leaks_the_dreaded_java
http://blogs.sun.com/fkieviet/entry/how_to_fix_the_dreaded

 - Chuck


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


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: OutOfMemoryError some time on some tomcat!!!!1

2010-11-22 Thread xu cheng
hi:
thanks for the references. I 'll read that.
by the way,
*hanging onto a reference to an object from your webapp classes, preventing
the old webapp deployment from being garbage collected. *

what kind of object do you mean by saying this? classes relevant to the
class loader? or something else? for example?
thanks


2010/11/23 Caldarale, Charles R chuck.caldar...@unisys.com

  From: xu cheng [mailto:xcheng@gmail.com]
  Subject: Re: OutOfMemoryError some time on some tomcat1

  I just kept redeploying apps , and the perm gen keep
  growing each time I deploy the same app. and when I
  undeploy the app, the perm gen didn't clean the garbage

 Exactly the situation I suggested the other day: you have something that's
 hanging onto a reference to an object from your webapp classes, preventing
 the old webapp deployment from being garbage collected.  Again, read this:

 http://wiki.apache.org/tomcat/FAQ/Memory

 Also, take a look at these:

 http://blogs.sun.com/fkieviet/entry/classloader_leaks_the_dreaded_java
 http://blogs.sun.com/fkieviet/entry/how_to_fix_the_dreaded

  - Chuck


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


 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org




Re: OutOfMemoryError some time on some tomcat!!!!1

2010-11-22 Thread Daniel Baktiar
hi charles,

please allow me to disagree to that hanging onto reference as the main
issue.

permgen space is garbage collector's specific issue, not general hanging
onto reference issue. it is caused by redeployment, which is the metadata
for classes, marked to be permanent generation by the hotspot garbage
collector. when you deploy new classes, the class loader will introduce
memory usages that will also marked as permanent generation.

permgen is oracle hotspot specific implementation issue. you won't get it
when you run on oracle jrockit (which performs just in time compilation),
for example.
---
daniel baktiar
http://savinggaia.tritiumapps.com - saving the planet is everyone's
business!




On 23 November 2010 14:10, Caldarale, Charles R
chuck.caldar...@unisys.comwrote:

  From: xu cheng [mailto:xcheng@gmail.com]
  Subject: Re: OutOfMemoryError some time on some tomcat1

  I just kept redeploying apps , and the perm gen keep
  growing each time I deploy the same app. and when I
  undeploy the app, the perm gen didn't clean the garbage

 Exactly the situation I suggested the other day: you have something that's
 hanging onto a reference to an object from your webapp classes, preventing
 the old webapp deployment from being garbage collected.  Again, read this:

 http://wiki.apache.org/tomcat/FAQ/Memory

 Also, take a look at these:

 http://blogs.sun.com/fkieviet/entry/classloader_leaks_the_dreaded_java
 http://blogs.sun.com/fkieviet/entry/how_to_fix_the_dreaded

  - Chuck


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




Re: How to access JSP and Servlet remotely ?

2010-11-22 Thread surya.prakash

even im facing same problem. i need to run jsp file from another system.

-- 
View this message in context: 
http://old.nabble.com/How-to-access-JSP-and-Servlet-remotely---tp20558511p30283777.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org