You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by David kerber <dc...@verizon.net> on 2015/10/20 15:20:15 UTC

Tracking down memory leak

I'm trying to track down the source of a memory leak in one of my 
applications.  I have examined the code but have been unable to fix it, 
so am looking for some way of instrumenting my app while running on the 
server.  What is the easiest/best (I realize those two criteria may not 
give the same answer!) way?

Running TC 8.0.20-something, JRE 8.0.something recent, on windows Server 
2012 R2.

Thanks for any suggestions!
Dave

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


Re: Tracking down memory leak

Posted by David kerber <dc...@verizon.net>.
On 10/21/2015 1:08 PM, Christopher Schultz wrote:
> Rallavagu,
>
> On 10/20/15 9:46 AM, Rallavagu wrote:
>> Please take a look at Memory Analyzer tool
>> (http://www.eclipse.org/mat/). Run the app and take the heap dump while
>> app is running and use the tool to analyze it. You could use VisualVM
>> with plugins to get instrumentation or you could use hprof
>> (http://docs.oracle.com/javase/7/docs/technotes/samples/hprof.html)
>
> +1
>
> If you have a huge number of a certain type of object, that can help you
> understand what is going on. I use YourKit (I get a free license as an
> ASF committer) and it can do things like find memory-consuming object
> trees, like maybe a cache that is taking up 3GiB when you thought it
> would maybe stop at 100MiB.

Thanks for the suggestion, guys!  I used visualvm and was able to get it 
straightened out.


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


Re: Tracking down memory leak

Posted by Christopher Schultz <ch...@christopherschultz.net>.
Rallavagu,

On 10/20/15 9:46 AM, Rallavagu wrote:
> Please take a look at Memory Analyzer tool
> (http://www.eclipse.org/mat/). Run the app and take the heap dump while
> app is running and use the tool to analyze it. You could use VisualVM
> with plugins to get instrumentation or you could use hprof
> (http://docs.oracle.com/javase/7/docs/technotes/samples/hprof.html)

+1

If you have a huge number of a certain type of object, that can help you
understand what is going on. I use YourKit (I get a free license as an
ASF committer) and it can do things like find memory-consuming object
trees, like maybe a cache that is taking up 3GiB when you thought it
would maybe stop at 100MiB.

-chris

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


Re: Tracking down memory leak

Posted by Rallavagu <ra...@gmail.com>.
Please take a look at Memory Analyzer tool 
(http://www.eclipse.org/mat/). Run the app and take the heap dump while 
app is running and use the tool to analyze it. You could use VisualVM 
with plugins to get instrumentation or you could use hprof 
(http://docs.oracle.com/javase/7/docs/technotes/samples/hprof.html)

HTH

On 10/20/15 6:20 AM, David kerber wrote:
> I'm trying to track down the source of a memory leak in one of my
> applications.  I have examined the code but have been unable to fix it,
> so am looking for some way of instrumenting my app while running on the
> server.  What is the easiest/best (I realize those two criteria may not
> give the same answer!) way?
>
> Running TC 8.0.20-something, JRE 8.0.something recent, on windows Server
> 2012 R2.
>
> Thanks for any suggestions!
> Dave
>
> ---------------------------------------------------------------------
> 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