Return-Path: Delivered-To: apmail-new-httpd-archive@apache.org Received: (qmail 12441 invoked by uid 500); 11 Apr 2001 23:12:38 -0000 Mailing-List: contact new-httpd-help@apache.org; run by ezmlm Precedence: bulk Reply-To: new-httpd@apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list new-httpd@apache.org Received: (qmail 12426 invoked from network); 11 Apr 2001 23:12:36 -0000 Sender: gregames@Mail.MeepZor.Com Message-ID: <3AD4E486.EC619F7D@remulak.net> Date: Wed, 11 Apr 2001 19:11:02 -0400 From: Greg Ames X-Mailer: Mozilla 4.75 [en] (X11; U; Linux 2.2.17-21mdk i686) X-Accept-Language: en MIME-Version: 1.0 To: new-httpd@apache.org Subject: Re: No processes left after big AB test References: <3AD3175C.627D5DF6@raleigh.ibm.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Spam-Rating: h31.sny.collab.net 1.6.2 0/1000/N "Paul J. Reder" wrote: > By the way, when I start Apache then run ps -efH (with no server load) I get something like > webadmin 21803 1 0 10:07 pts/3 00:00:00 httpd -d /home/webadmin/Apache (1 top level Apache) > webadmin 21805 21803 0 10:07 pts/3 00:00:00 httpd -d /home/webadmin/Apac (Start_Server number of these) > webadmin 21808 21805 0 10:07 pts/3 00:00:00 httpd -d /home/webadmin/Ap (1 per Start_server) > webadmin 21809 21808 0 10:07 pts/3 00:00:00 httpd -d /home/webadmin/ (threads_per_Child number of these > webadmin 21812 21808 0 10:07 pts/3 00:00:00 httpd -d /home/webadmin/ - > webadmin 21815 21808 0 10:07 pts/3 00:00:00 httpd -d /home/webadmin/ - > webadmin 21818 21808 0 10:07 pts/3 00:00:00 httpd -d /home/webadmin/ - > > I understand 21803 and I understand 21809 and its ilk. I also understand either 21805 or 21808 > but not both. What am I missing in the way that processes and threads are handled in APR/threaded mpm? > I hacked up apr/test/testthread.c so that the threads sleep for several seconds before exiting. This program creates 4 threads via apr_thread_create. When all 4 are sleeping, I see: [gregames@gandalf httpd-2.0]$ ps ax -HO ppid,wchan | grep testthread 3306 1152 rt_sig S pts/0 00:00:00 ./testthread 3307 3306 do_pol S pts/0 00:00:00 ./testthread 3308 3307 nanosl S pts/0 00:00:00 ./testthread 3309 3307 nanosl S pts/0 00:00:00 ./testthread 3310 3307 nanosl S pts/0 00:00:00 ./testthread 3311 3307 nanosl S pts/0 00:00:00 ./testthread ...so it looks like Linux is creating an extra thread/process for us (3307), probably when we do first pthread_create. Greg