jconsole question -- probably the wrong mailing list but here goes...
Stephen Ryan
stephen.ryan at corp.aol.com
Wed Apr 9 06:57:25 PDT 2008
Hi Luis.
I just discovered visualvm this morning in my quest. Its has some nice
features and all the same stuff that jconsole delivers as well.
Heres the top chunk of what jmap -histo delivers. Also the classes
loaded count is still increasing. Im starting to lean towards a bug in
the code of my webserver.
Size Count Class description
-------------------------------------------------------
70483456 210902 char[]
22539768 939157 java.lang.String
10608936 442039 java.util.HashMap$Entry
3876512 18922 java.util.HashMap$Entry[]
3823192 22119 * ConstMethodKlass
3046768 4349 byte[]
2724968 47155 java.lang.Object[] ...
Luis-Miguel Alventosa wrote:
> Hi Stephen,
>
> Could you try to use jmap -dump and/or jmap -histo to see the names
> of the instances being created?
>
> You could also have a look at VisualVM in order to profile the
> application.
>
> https://visualvm.dev.java.net
>
> Regards,
> Luis
>
> > On 4/9/2008 3:24 PM, Stephen Ryan wrote:
> >
> > Hi Alan,
> > Thanks for that but Im not sure its that at all. I've other servers
> > being monitored and Ive never seen jConsole have this effect. I did a
> > jmap on the server and saw some huge numbers. Im begining to think that
> > theres bad code thats causing classes to be loaded too many times. The
> > 'Classes' view in jConsole is showing me a constant rise in class
> > numbers. I would have expected this to be more or less stable,
> > considering that the server is serving about 4 requests per second. The
> > CPU is pretty busy too.Busy garbage collecting the eden space I guess.
> >
> > I was considering increasing the eden space to see if that alleavates
> > the problem, but if its a code problem, it wont help at all.
> >
> > Thanks!
> > Stephen.
> >
> > Alan Bateman wrote:
> >
> >> Stephen Ryan wrote:
> >>
> >>> Hi,
> >>>
> >>> I was wondering if its possible to get the size of the classes loaded
> >>> from jConsole. Im seeing a lot of GC's in the Eden Space in a server
> >>> thats basically doing nothing. Im thinking that the jvm is trying to
> >>> load classes in there that are just too close to the size of that
> space.
> >>>
> >>> Any help appreciated!
> >>>
> >>> Stephen.
> >>
> >> Classes are essentially allocated from the perm generation so I don't
> >> think this is what you are observing. Instead it is likely that you
> >> are observing the effect of the JMX agent in the target VM due to the
> >> polling by jconsole. Each time jconsole updates the display it must
> >> interact with agent in the agent VM so this means some objects are
> >> allocated which can lead to periodic scavenging that you observe. You
> >> can reduce the polling interval via jconsole's -interval=value option
> >> (interval is specified in seconds). The management interface for class
> >> loading doesn't include the size of the classes but if you try jstat
> >> then you can get this information (jstat -class <vmid> for example).
> >>
> >> -Alan.
>
--
Stephen Ryan
Principal QA Engineer
AOL Technologies Ireland Ltd.
3040 Lake Drive, City West Business Campus
Saggart, County Dublin, Ireland
Work: +353 1 4692115
stephen.ryan at corp.aol.com
"To destroy the concept of money, is going to take money" -Stang
More information about the serviceability-dev
mailing list