From: Rahul Pydimukkala <prahul@cse.iitk.ac.in>
To: Andy Lutomirski <luto@myrealbox.com>
Cc: kyle <kylewong@southa.com>, linux-kernel@vger.kernel.org
Subject: Re: apache threads not balanced over all CPU cores, schedular problem or apache?
Date: Fri, 14 Nov 2008 16:08:06 +0000 [thread overview]
Message-ID: <20081114160758.GA4074@csews22.cse.iitk.ac.in> (raw)
In-Reply-To: <491CF509.7010101@myrealbox.com>
On 22:48 Thu 13 Nov , Andy Lutomirski wrote:
> kyle wrote:
> >top - 12:44:42 up 8 days, 15:45, 7 users, load average: 2.07, 1.86, 2.02
> >Tasks: 251 total, 1 running, 249 sleeping, 0 stopped, 1 zombie
> >Cpu0 : 0.5%us, 0.5%sy, 0.0%ni, 99.0%id, 0.0%wa, 0.0%hi, 0.0%si,
> >0.0%st
> >Cpu1 : 14.6%us, 4.4%sy, 0.0%ni, 62.6%id, 17.0%wa, 0.0%hi, 1.5%si,
> >0.0%st
> >Cpu2 : 4.3%us, 1.4%sy, 0.0%ni, 93.8%id, 0.0%wa, 0.5%hi, 0.0%si,
> >0.0%st
> >Cpu3 : 0.0%us, 0.0%sy, 0.0%ni, 98.0%id, 2.0%wa, 0.0%hi, 0.0%si,
> >0.0%st
> >Mem: 8117172k total, 8060936k used, 56236k free, 357488k buffers
> >Swap: 208824k total, 8436k used, 200388k free, 5765168k cached
>
> Looks like you're mostly idle or waiting for I/O. From this
> information, it looks like the kernel is probably doing the right thing:
> keeping a lot of processes that share the same memory and run for very
> short periods of time on the same cores to minimize cacheline bouncing.
>
> >
> >All httpd are running on cpu1 and cpu2 only for several hours, after that,
> >all httpd may run on cpu1 and cpu3, or cpu2 and cpu3, etc. again for
> >several
> >hours.
> >
> >Since the apache is in prefork mode, every httpd instance should be quite
> >independant, I suppose the CPU schedular should balance the processes over
> >the avaiable cores. However never seen httpd processes evenly distributed
> >to
> >3 cores, or 4 cores.
>
> Is there any reason to expect it to run faster if it were balanced evenly?
Totally convincing. Thanks Andy for making this clear. I/O-bound processes
reap no advantage from processor-level parallelism.
-
Rahul
prev parent reply other threads:[~2008-11-14 10:01 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-13 4:58 kyle
2008-11-13 14:34 ` Rahul Pydimukkala
2008-11-13 11:37 ` kyle
2008-11-13 11:46 ` kyle
2008-11-13 19:12 ` Rahul Pydimukkala
2008-11-13 13:12 ` kyle
2008-11-13 19:37 ` Rahul Pydimukkala
2008-11-14 3:48 ` Andy Lutomirski
2008-11-14 16:08 ` Rahul Pydimukkala [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20081114160758.GA4074@csews22.cse.iitk.ac.in \
--to=prahul@cse.iitk.ac.in \
--cc=kylewong@southa.com \
--cc=linux-kernel@vger.kernel.org \
--cc=luto@myrealbox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®