How to collect Thread dump and Heap Dump ?

How to collect Thread dump and Heap Dump ?

For collecting Thread dump:

Login to the application and in the browser invoke the URL  http://servername:port/jsp/ThreadDump.jsp 

If the application is running in command mode , then at the time the issue occurrence you can collect thread dump by pressing CTRL+Fn+B ( For Windows) and CTRL+\ ( for Linux) . This will generate thread dump in the command prompt. Copy the complete text and paste it in Notepad/Wordpad as Threaddump1.txt. Sameway proceed to take two more dumps by using the same commands.

For collecting Heap Dump:

It is necessary to install JDK and JMAP. Once you install this in Windows machine you can generate the heap dump using the command ,

psexec -s jmap -dump:format=b,file=cheap.bin <PID>

PID - It is the process ID

Direct Links to download,



After downloading JMAP, extract and move to Java folder under program files where JDK usually installs by default.

So after executing the command, you get confirmation as below.



cheap.bin will be stored under mostly in C:\Windows\System32\cheap.bin


Other ways to collect heapdump,

Apart from the above details collect the Logs folder present in the ServiceDeskPlus-MSP folder for analysis which has Currentqueriesinformation.html,connectiondump files.


For Linux :

jmap -dump:file=heapdump.bin pid


Herewith i have attached 2 Gif on how to generate Thread dump and heap dump in Linux.

 



                  New to ADManager Plus?

                    New to ADSelfService Plus?

                      • Related Articles

                      • How to address Performance issue ?

                        Application will face the performance issue because of couple of reasons. 1. System requirements are not met: Refer this link to ensure the specifications are met as per the standards. 2. Application architecture should be 64-bit for better ...
                      • How to enable Performance monitoring tool ?

                        To analyze Performance issues, logs and tuning alone won't be sufficient. Hence, we need to follow a few steps to enable the Performance Monitoring tool, which will monitor the application's performance and automatically collects the data when the ...
                      • Performance Debug

                        For Performance/slowness issues instead of taking Threaddump manually or instead of invoking PerformanceTool make use of the below URL when the issue occurs, http://servername:portnumber/servlet/PerformanceDebug The above URL works even when the ...
                      • Performance Issue - Inputs required and details to be checked

                        When there are performance issue's are reported\seen in the application. Check and update the support team with the below details: 1. Is the CPU usage spiking above 80% ? 2. Any specific module being unusable ? 3. Application getting crashed ? 4. ...
                      • Steps to take PGSQL Dump Backup and Restore

                        PGSQL – DUMP – Backup Procedure : Login to the MSP application server and perform the below steps, 1. Start the application To take Postgres (Psql) Dump : 3. Open a command prompt and navigate into <ServiceDeskPlus-MSP>/pgsql/bin directory. 4. ...