You can enable automatic Java heap dumps to troubleshoot performance issues and OutOfMemoryError(OOM) in Clarity in CSA or properties.xml.
To ensure an automatic heap dump is generated on OOM for Clarity, enable in CSA:
Next time there is an Out of Memory error (java.lang.OutOfMemoryError: Java heap space), a heap dump .hprof file will be generated under the path folder location indicated.
You can use a 3rd party tool to analyze it or contact Broadcom Support for further assistance.
Since the file is a binary file, you must zip it before moving from the server and providing to Support to avoid corruption
Ways of setting up the JVM outputs with examples:
-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=C:\temp\myheapdump.hprof
If you specify the file name .hprof, then only 1 file will be generated. Note: If a new OOM occurs, the file will be overwritten.
This is not a good option if you have lots of occurrences and need to track them back in time. This is a good option if you have a limited disk space
If you specify a directory, such as :
-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=C:\temp
Every time there is an OOM, a heap dump will be placed in this directory, and the files will not be overwritten. This may be useful if you have multiple OOM events. Ensure you have enough disk space
Attention: Since the heap dumps are large files (usually 2-6GB depending on JVM size), you must ensure you have enough disk space to enable them. This is particularly important if you do not specify a filename as multiple heap dumps may be created in the folder.
When generating Java Heap Dump check to ensure spaces are properly used within the argument string of the APP JVM (Application Java VM Parameters) and/or BG JVM (Background Java VM Parameters).