tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pierre Goupil" <goupilpie...@gmail.com>
Subject Re: Servlet Memory Leak
Date Fri, 29 Aug 2008 17:56:52 GMT
Hello,

Interesting thread, indeed. But I've googled around and can't find JMap
homepage, I'm afraid.  It seems like some other programs has the same name.
Even with the profiler keyword, it doesn't give the page I'm looking for.

A clue, anyone, please ?

Cheers,

Pierre


On Fri, Aug 29, 2008 at 7:38 PM, Martin Gainty <mgainty@hotmail.com> wrote:

>
> FYI
> you'll need to run JDK 6 for jmap
>
> Martin
> ______________________________________________
> Disclaimer and confidentiality note
> Everything in this e-mail and any attachments relates to the official
> business of Sender. This transmission is of a confidential nature and Sender
> does not endorse distribution to any party other than intended recipient.
> Sender does not necessarily endorse content contained within this
> transmission.
>
>
> > Date: Fri, 29 Aug 2008 09:44:41 -0700
> > From: huntrods@nucleus.com
> > To: users@tomcat.apache.org
> > Subject: Re: Servlet Memory Leak
> >
> > >
> > > I have a fairly small memory leak in a servlet (Tomcat 6.0) running on
> a
> > > Windows 2003 server. I have been looking into memory profiling to help
> me
> > > find the leak but nothing seems to be or do what I need. Simply put I
> want a
> > > list of all of the objects/primitives (and if possible their values)
> that
> > > are in memory. It would be really nice if I didn't have to bring Tomcat
> down
> > > at all to do this analysis as the servlet is running in a production
> > > environment. Does anyone know of a decent free tool that does such a
> thing?
> > > If not, what would be a good route to take to find this leak?
> > >
> > > Thanks a ton.
> > >
> > I just finished debugging a major memory leak in my servlet application.
> > Try running the tool "jmap" that comes with java. It works great with
> > Tomcat - just find the PID of the Tomcat (java) instance and run it on
> that.
> >
> > For example, fire up Windows Task Manager, go to Applications and find
> > Tomcat. Right-click and choose "go to process". This will move you to
> > the Process pane highlighting the Tomcat (java) process ID.
> >
> > Now open a command (console) window and (assuming you have Java paths
> > set correctly), type:
> >
> > jmap -histo PID >output.txt
> >
> > (or >> output.txt - although I used sequentially numbered output files)
> >
> > This will capture the stack info into a file for analysis. The PID is
> > the process ID you noted from the Task Manager. If you run this just
> > after you start Tomcat, then a few times after doing the things that you
> > suspect trigger the memory leak, you should see objects in the map that
> > you can identify as not getting released and thus zero in on the leak.
> >
> > Cheers,
> >
> > -Richard
> >
> > ---------------------------------------------------------------------
> > To start a new topic, e-mail: users@tomcat.apache.org
> > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> > For additional commands, e-mail: users-help@tomcat.apache.org
> >
>
> _________________________________________________________________
> Be the filmmaker you always wanted to beā€”learn how to burn a DVD with
> Windows(R).
> http://clk.atdmt.com/MRT/go/108588797/direct/01/
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message