Checking the number of LWP (threads) in Linux

1 · Benjamin Cane · June 25, 2011, 1:24 a.m.
Linux has these nice little processes called LWP (Light Weight Process) or otherwise known as threads. Generally these are spawned by 1 master process that will show up in your normal ps output. # ps -elf | wc -l 145 So does this mean your system only has 145 processes running? No. If you run ps with a -T you will see all of the threads as well. # ps -elfT | wc -l 275 As you can see the process count jumped significantly due to threads....