1

I am trying profiling my web Application which is a very big Application and takes lots of memory in cache and other process so it is very difficult to take heap dump and then analyze or even when I am trying to analyze it through JProfiler it is also working very slow. Is there a way I can easily do that. My application is almost taking 30 GB out of 120 GB RAM.

I have read somewhere that we can allocate different amount of memory to different parts of heap. We didn't do such thing in our application. We have just given -xmx -110g. That means we have given Max RAM of 110 GB. can I check how much memory it allocates to different blocks like old gen, eden space, survivor space.

NIVESH SENGAR
  • 1,285
  • 5
  • 19
  • 43

2 Answers2

1

Profiling any system that uses 30gb is going to be a challenge. Profiling collects a significant amount of information, and that adds even more overhead.

The best way forward is to break your application into modules - you did create a modular application, right? Then you can profile each module on it's own using sample data. That way you limit the overhead and the amount of memory consumed.

You can refer to http://java.dzone.com/articles/java-performance-tuning?page=0,1 for some performance tuning tips, you can set different memory usage levels.

Ewald
  • 5,691
  • 2
  • 27
  • 31
0

If you want to know

how much memory it allocates to different blocks like old gen, eden space, survivor space.

you can use this class: http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/management/ManagementFactory.html and access this information using JMX, for example.

dbf
  • 6,399
  • 2
  • 38
  • 65