LinuxAnswers - the LQ Linux tutorial section.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 10-04-2010, 03:58 PM   #1
Registered: Oct 2005
Posts: 540

Rep: Reputation: 32
process vs threads

Hi, anyone knows how I can distinguish whether I'm looking at a process or a thread when I issue "ps -ef"? Reason I'm asking is in Apache, I can configure the MPM to use prefork or worker. Whenever new connection is required, prefork adds an additional process, whereas worker adds an additional thread to the process.
Old 10-04-2010, 06:04 PM   #2
Registered: Nov 2005
Distribution: Fedora, Redhat
Posts: 372

Rep: Reputation: 101Reputation: 101
You need the 'L' flag, ps -eLf

(NLWP is number of threads; LWP is thread ID.)

There is not much of a performance difference between a process and a thread in Linux (from what I've read).

Last edited by tommylovell; 10-04-2010 at 06:08 PM.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Number of threads per process avijitp Solaris / OpenSolaris 2 06-22-2009 09:18 AM
process and threads jkeertir Linux - Newbie 1 04-16-2009 12:01 PM
Can i find all threads by a process? msbinu Linux - Newbie 1 09-19-2008 01:32 AM
How to View Threads per Process Shashi Linux - Software 0 08-01-2003 02:37 AM
Threads And Process Penguinizer Programming 1 02-18-2003 10:39 PM

All times are GMT -5. The time now is 11:25 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration