Monday 2 April 2012

perf tools

Heap Analyser - To analyse HeapDumps

Thread Analyser - To analyse thread dumps

GC Analyser - To analyse GC patterns - (native_stderr.log)

Recently we had an issue wherein one of the server threw OutOfMemory exceptions, steps we did to find out the cause:

1. Get the Heapdumps, native_stderr, thread dumps from the server.

2. Open the heapdumps with heapdump analyser, the tool shows you the leaks, browse through the childs until you hit the leaf node, if you just look through the classes you should get a fair amount of idea as to which area of classes are failing.

3.Open types in heap analyser, see the size of objects, that should give you some pointers.

4. Once you are done with heaps, open GC analyser and check for AF (allocation failures) if there are too many and you see it spiking try to find out the time that has happened.

5. With the time on hand, go to your systemout logs and find out what exactly happened in the server. These steps should take you closer to the cause.

No comments:

Post a Comment