Java Memory slowly creeping up

We are running Jive on a fairly powerful machine Xeon 3ghz with 4GB of ram.

On the server properties menu I have noticed Java Memory usage slowly creeping up over the past few days. We started with about 16MB of 493MB of memory used when we started the server about 6 days ago, and now are at about 74MB of 493MB used. We have not had many people logging in, only about 12 concurrent max. Any reason why this might be occuring?

Thanks for all the answers in advance,

Jason

Hey Jason,

Jive Messenger is written in Java which means that memory management is controlled by the Java Virtual Machine (JVM). When a Java application requires memory the JVM has two options, 1) use available memory or 2) if memory is reaching certain limit then the Garbage Collector (GC) will try to release unused object thus releasing memory. Since option 2 is more expensive that option 1, the JVM will usually try to use assigned and free memory.

This means, that what you are seeing is not necessarily a memory leak but normal Java memory management. When launching a Java application you can specify certain parameters that will influence they way the GC works. I would recommend changing these parameters only if you are having some performance issues and if you have previously tested them in a testing environment.

http://java.sun.com/performance/reference/whitepapers/tuning.html

http://java.sun.com/docs/hotspot/gc5.0/gc_tuning_5.html

http://www.caucho.com/resin-3.0/performance/jvm-tuning.xtp

On the other hand, if memory consumption is reaching the maximum limit and nothing is being released after running full GC then we should try to locate if there is a memory leak going on or if we need to finetune any caching value.

Regards,

– Gato