What Is Pstack in Linux?
Contents the Pstack Command Displays a Stack Trace for Each Process. … You Can Use the Pstack Command to Determine Where a Process Is Hung. the Only Option...
The pstack command displays a stack trace for each process. … You can use the pstack command to determine where a process is hung. The only option that is allowed with this command is the process ID of the process that you want to check.
How do I run a Pstack in Linux?
To get the pstack and gcore, here is the procedure:
- Get the process ID of the suspect process: # ps -eaf | grep -i suspect_process.
- Use the process ID to generate the gcore: # gcore <proc_id> …
- Now generate the pstack based on the generated gcore file: …
- Now create a compressed tar ball with the gcore.
Must Read
How do I see running processes in Linux?
Trace Linux Process PID
If a process is already running, you can trace it by simply passing its PID as follows; this will fill your screen with continues output that shows system calls being made by the process, to end it, press [Ctrl + C] . $ sudo strace -p 3569 strace: Process 3569 attached restart_syscall(<…