HOW TO : Check the number of threads spawned (opened) by a process

If you ever wanted to check how many threads a particular process spawned off in Linux, you can use

  1. Find the PID of the process by running[code] ps -ef | grep -i PROCES_NAMEĀ  [/code]
  2. Check the number of threads opened by this process by running[code] <code>ps uH p <PID_OF_PROCESS> | wc -l [/code]