Required Data: Java Heap Memory Issue On Linux

Issue

Your Jenkins instance is experiencing high Java heap utilization.

Environment

  • CloudBees Jenkins Enterprise (CJE)
  • CloudBees Jenkins Platform (CJP)
  • Operating System: Linux

Resolution

Download the jenkinsjmap.sh script.

The jenkinsjmap.sh script will need to be made executable by running: chmod +x jenkinsjmap.sh .

Your environment should be configured as documented in Prepare jenkins for support.

If you are experiencing high Java heap utilization please collect the following data while the issue is occurring:

  1. Generate a Support Bundle.

  2. Run the jenkinsjmap.sh as the root user in one of the following modes:

  • ./jenkinsjmap.sh PID - for default mode which generates jmap -heap output and jmap -histo output
  • ./jenkinsjmap.sh PID 1 - for heapdump mode which generates jmap -heap output, jmap -histo output, and a heapdump file binary format

The data will be generated in the same directory where the script is ran.

In case you could not run jenkinsjmap.sh to get a heap dump by adding to your existing JAVA_ARGS
-XX:+HeapDumpOnOutOfMemoryError, then the next time an out of memory exception is thrown the JVM will generate a heap dump file. You
can also set -XX:HeapDumpPath=SPECIFY_PATH to have the heap dump written to that location. Besides, the classic way explained in
How to generate a heap dump.

  1. Upload the Support Bundle to your support ticket for review. Compress the data generated by the jenkinsjmap.sh script
    (or <heapdump>.bin) and upload it via our upload site. Please update your support ticket with the name of the file. Please note
    that the Support Core plugin v2.35 and higher will include the verbose gc logs.
    If you are using an older version please include the
    verbose gc logs (from set -Xloggc as explained in Prepare jenkins for support) in the compressed data uploaded
    to our upload site.
Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.