Issue
- In order to diagnose a Managed Master/CJOC I need to extract a Heap/Thread dump of JVM.
Environment
- CloudBees Jenkins Enterprise (CJE) - AWS
Resolution
You could enter on the tenant, in this case on the cjoc
[user:~/cje-project] $ cje run ssh-into-tenant cjoc
see the PID of the Jenkins process
jenkins@ip-192-168-1-3:/$ jps
6 jenkins.war
3467 Jps
and then you can extract the heap and thread dump by using the PID 6
output a thread dump to Jenkins log file, also to worker in stdout log file
jenkins@ip-192-168-1-3:/$ kill -3 6
output a thread dump to terminal stdout
jenkins@ip-192-168-1-3:/$ jstack 6
generate a Heap dump file named heap.bin
jenkins@ip-192-168-1-3:/tmp$ jmap -dump:format=b,file=heap.bin 6
0 Comments