You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by hruesga <lo...@HOTMAIL.COM> on 2009/08/17 17:02:27 UTC
Garbage collector
Listers:
We are trying to enable the garbage collector log for jvm to see what
happens with our leak memory issue, i've already try to export CATALINA_OPTS
variable but i'm not able to see any log.
Maybe there's something that i did wrong.
Any help will be greatly appreciate.
HR
--
View this message in context: http://www.nabble.com/Garbage-collector-tp25008420p25008420.html
Sent from the Tomcat - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: Garbage collector
Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: hruesga [mailto:lord_dynasty@HOTMAIL.COM]
> Subject: RE: Garbage collector
>
> for this reason i'm trying to enable the garbage collector
> to see what happens with the java threads.
Again: what *exactly* have you tried, and what are the results?
- 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-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: Garbage collector
Posted by hruesga <lo...@HOTMAIL.COM>.
George Sexton wrote:
>
> Have you ever tried running something like findbugs against your
> application
> to do a code analysis?
>
> http://findbugs.sourceforge.net/
>
> George Sexton
> MH Software, Inc.
> http://www.mhsoftware.com/
> Voice: 303 438 9585
>
>
>> -----Original Message-----
>> From: hruesga [mailto:lord_dynasty@HOTMAIL.COM]
>> Sent: Monday, August 17, 2009 9:25 AM
>> To: users@tomcat.apache.org
>> Subject: RE: Garbage collector
>>
>>
>> Sorry...
>>
>> Tomcat 5.5.25
>> Java: 1.5.0_12-b04
>> OS: Solaris 10
>>
>> We are facing a slow performance of one application, as far as we've
>> seeing
>> we have a max threads of 500 but only we see a max of 20 busy threads,
>> tomcat is configured to run with 3GB first there's no problem but 3 or
>> 4
>> hours later we start to suffer a leak of mem that force us to restart
>> the
>> web server.
>>
>> Our guess is to see what does java is doing with the memmory and find a
>> better configuration for the tomcat server, prior that we need to catch
>> the
>> garbage collector logs, but so far i'm not able to do this.
>>
>> Best Regards
>>
>>
>> Caldarale, Charles R wrote:
>> >
>> >> From: hruesga [mailto:lord_dynasty@HOTMAIL.COM]
>> >> Subject: Garbage collector
>> >>
>> >> Maybe there's something that i did wrong.
>> >
>> > For starters, not telling us your Tomcat version, JRE/JDK version, OS
>> > you're using, what's in your logs, etc.
>> >
>> > - Chuck
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>
>
Don't think that is related to the application itself, this "web
application" its only a jsp interface to run application for web users, if
we accdess the application through fat client is working fine, but the issue
is the memmory leak over Web for this reason i'm trying to enable the
garbage collector to see what happens with the java threads.
Thanks
--
View this message in context: http://www.nabble.com/Garbage-collector-tp25008420p25009267.html
Sent from the Tomcat - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: Garbage collector
Posted by George Sexton <ge...@mhsoftware.com>.
Have you ever tried running something like findbugs against your application
to do a code analysis?
http://findbugs.sourceforge.net/
George Sexton
MH Software, Inc.
http://www.mhsoftware.com/
Voice: 303 438 9585
> -----Original Message-----
> From: hruesga [mailto:lord_dynasty@HOTMAIL.COM]
> Sent: Monday, August 17, 2009 9:25 AM
> To: users@tomcat.apache.org
> Subject: RE: Garbage collector
>
>
> Sorry...
>
> Tomcat 5.5.25
> Java: 1.5.0_12-b04
> OS: Solaris 10
>
> We are facing a slow performance of one application, as far as we've
> seeing
> we have a max threads of 500 but only we see a max of 20 busy threads,
> tomcat is configured to run with 3GB first there's no problem but 3 or
> 4
> hours later we start to suffer a leak of mem that force us to restart
> the
> web server.
>
> Our guess is to see what does java is doing with the memmory and find a
> better configuration for the tomcat server, prior that we need to catch
> the
> garbage collector logs, but so far i'm not able to do this.
>
> Best Regards
>
>
> Caldarale, Charles R wrote:
> >
> >> From: hruesga [mailto:lord_dynasty@HOTMAIL.COM]
> >> Subject: Garbage collector
> >>
> >> Maybe there's something that i did wrong.
> >
> > For starters, not telling us your Tomcat version, JRE/JDK version, OS
> > you're using, what's in your logs, etc.
> >
> > - Chuck
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Garbage collector
Posted by Rusty Wright <ru...@gmail.com>.
In my /etc/init.d/tomcat shell startup script for linux I have
JAVA_OPTS="-server"
JAVA_OPTS="${JAVA_OPTS} -Xmx512m"
JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256m"
JAVA_OPTS="${JAVA_OPTS} -XX:+PrintGCDetails"
JAVA_OPTS="${JAVA_OPTS} -XX:+PrintGCTimeStamps"
JAVA_OPTS="${JAVA_OPTS} -XX:+UseConcMarkSweepGC"
JAVA_OPTS="${JAVA_OPTS} -XX:+CMSIncrementalMode"
JAVA_OPTS="${JAVA_OPTS} -XX:-TraceClassUnloading"
JAVA_OPTS="${JAVA_OPTS} -verbose:gc"
export JAVA_OPTS
The export line is necessary. The following 3 lines are what I think
turn on garbage collecting logging:
JAVA_OPTS="${JAVA_OPTS} -XX:+PrintGCDetails"
JAVA_OPTS="${JAVA_OPTS} -XX:+PrintGCTimeStamps"
JAVA_OPTS="${JAVA_OPTS} -verbose:gc"
Then, in my catalina.out I have lines (the CMS- lines are from
UseConcMarkSweepGC):
48124.665: [GC [1 CMS-initial-mark: 39226K(67176K)] 40336K(71656K),
0.0090660 secs]
48124.674: [CMS-concurrent-mark-start]
48125.090: [CMS-concurrent-mark: 0.416/0.416 secs]
48125.091: [CMS-concurrent-preclean-start]
48125.091: [CMS-concurrent-preclean: 0.000/0.000 secs]
48125.097: [GC[YG occupancy: 1135 K (4480 K)]48125.097: [Rescan
(parallel) , 0.0093270 secs]48125.106: [weak refs processing, 0.0003890
secs] [1 CMS-remark: 39226K(67176K)] 40362K(71656K), 0.0101020 secs]
48125.107: [CMS-concurrent-sweep-start]
48125.158: [CMS-concurrent-sweep: 0.050/0.050 secs]
48125.158: [CMS-concurrent-reset-start]
48125.189: [CMS-concurrent-reset: 0.031/0.031 secs]
48402.052: [GC 48402.052: [ParNew: 4415K->0K(4480K), 0.0178790 secs]
43420K->39329K(71656K), 0.0181320 secs]
hruesga wrote:
> i'fe tried to export CATALINA_OPTS setting as:
>
> execute:
>
> export CATALINA_OPTS=-Xloggc:/logs/gc.log
> result: gc.log file doesn't create
>
> java -verbose:gc
> result: nothing happpens.
>
>
>
>
>
> Caldarale, Charles R wrote:
>>> From: hruesga [mailto:lord_dynasty@HOTMAIL.COM]
>>> Subject: Re: Garbage collector
>>>
>>> -Xmx3072m -Xms3072m
>> Unless you're in a 64-bit environment, that doesn't stand a chance of
>> working.
>>
>>> Maz Threads= 500
>> Is that supposed to be Max? Where do you have that set?
>>
>>> minSpareThreads=25
>>> maxSpareThreads=75
>> The threads settings are not really relevant to getting GC logs.
>>
>> For the third time, tell us *exactly* what you're doing - step by step.
>>
>> - 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-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
>>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: Garbage collector
Posted by hruesga <lo...@HOTMAIL.COM>.
i'fe tried to export CATALINA_OPTS setting as:
execute:
export CATALINA_OPTS=-Xloggc:/logs/gc.log
result: gc.log file doesn't create
java -verbose:gc
result: nothing happpens.
Caldarale, Charles R wrote:
>
>> From: hruesga [mailto:lord_dynasty@HOTMAIL.COM]
>> Subject: Re: Garbage collector
>>
>> -Xmx3072m -Xms3072m
>
> Unless you're in a 64-bit environment, that doesn't stand a chance of
> working.
>
>> Maz Threads= 500
>
> Is that supposed to be Max? Where do you have that set?
>
>> minSpareThreads=25
>> maxSpareThreads=75
>
> The threads settings are not really relevant to getting GC logs.
>
> For the third time, tell us *exactly* what you're doing - step by step.
>
> - 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-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>
>
--
View this message in context: http://www.nabble.com/Garbage-collector-tp25008420p25010241.html
Sent from the Tomcat - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: Garbage collector
Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: hruesga [mailto:lord_dynasty@HOTMAIL.COM]
> Subject: Re: Garbage collector
>
> -Xmx3072m -Xms3072m
Unless you're in a 64-bit environment, that doesn't stand a chance of working.
> Maz Threads= 500
Is that supposed to be Max? Where do you have that set?
> minSpareThreads=25
> maxSpareThreads=75
The threads settings are not really relevant to getting GC logs.
For the third time, tell us *exactly* what you're doing - step by step.
- 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-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Garbage collector
Posted by hruesga <lo...@HOTMAIL.COM>.
Mark Thomas-23 wrote:
>
> hruesga wrote:
>> Sorry...
>>
>> Tomcat 5.5.25
>> Java: 1.5.0_12-b04
>> OS: Solaris 10
>>
>> We are facing a slow performance of one application, as far as we've
>> seeing
>> we have a max threads of 500 but only we see a max of 20 busy threads,
>> tomcat is configured to run with 3GB first there's no problem but 3 or 4
>> hours later we start to suffer a leak of mem that force us to restart the
>> web server.
>>
>> Our guess is to see what does java is doing with the memmory and find a
>> better configuration for the tomcat server, prior that we need to catch
>> the
>> garbage collector logs, but so far i'm not able to do this.
>
> So what configuration option have you tried that isn't working?
>
> Mark
>
>
> -Xmx3072m -Xms3072m
> Maz Threads= 500
> minSpareThreads=25
> maxSpareThreads=75
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>
>
--
View this message in context: http://www.nabble.com/Garbage-collector-tp25008420p25009288.html
Sent from the Tomcat - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Garbage collector
Posted by Mark Thomas <ma...@apache.org>.
hruesga wrote:
> Sorry...
>
> Tomcat 5.5.25
> Java: 1.5.0_12-b04
> OS: Solaris 10
>
> We are facing a slow performance of one application, as far as we've seeing
> we have a max threads of 500 but only we see a max of 20 busy threads,
> tomcat is configured to run with 3GB first there's no problem but 3 or 4
> hours later we start to suffer a leak of mem that force us to restart the
> web server.
>
> Our guess is to see what does java is doing with the memmory and find a
> better configuration for the tomcat server, prior that we need to catch the
> garbage collector logs, but so far i'm not able to do this.
So what configuration option have you tried that isn't working?
Mark
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: Garbage collector
Posted by hruesga <lo...@HOTMAIL.COM>.
Sorry...
Tomcat 5.5.25
Java: 1.5.0_12-b04
OS: Solaris 10
We are facing a slow performance of one application, as far as we've seeing
we have a max threads of 500 but only we see a max of 20 busy threads,
tomcat is configured to run with 3GB first there's no problem but 3 or 4
hours later we start to suffer a leak of mem that force us to restart the
web server.
Our guess is to see what does java is doing with the memmory and find a
better configuration for the tomcat server, prior that we need to catch the
garbage collector logs, but so far i'm not able to do this.
Best Regards
Caldarale, Charles R wrote:
>
>> From: hruesga [mailto:lord_dynasty@HOTMAIL.COM]
>> Subject: Garbage collector
>>
>> Maybe there's something that i did wrong.
>
> For starters, not telling us your Tomcat version, JRE/JDK version, OS
> you're using, what's in your logs, etc.
>
> - 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-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>
>
--
View this message in context: http://www.nabble.com/Garbage-collector-tp25008420p25008827.html
Sent from the Tomcat - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: Garbage collector
Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: hruesga [mailto:lord_dynasty@HOTMAIL.COM]
> Subject: Garbage collector
>
> Maybe there's something that i did wrong.
For starters, not telling us your Tomcat version, JRE/JDK version, OS you're using, what's in your logs, etc.
- 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-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Garbage collector
Posted by Ronald Klop <ro...@base.nl>.
This can be quite informative.
jstat -gc <pid> 5s
Ronald.
Op maandag, 17 augustus 2009 17:02 schreef hruesga <lo...@HOTMAIL.COM>:
>
>
> Listers:
>
> We are trying to enable the garbage collector log for jvm to see what
> happens with our leak memory issue, i've already try to export CATALINA_OPTS
> variable but i'm not able to see any log.
> Maybe there's something that i did wrong.
>
> Any help will be greatly appreciate.
>
> HR
> --
> View this message in context: http://www.nabble.com/Garbage-collector-tp25008420p25008420.html
> Sent from the Tomcat - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>
>
>
>