On Tue, Oct 7, 2014 at 8:59 PM, Ruediger Pluem <rpl...@apache.org> wrote: > > On 10/07/2014 05:16 PM, yla...@apache.org wrote: >> URL: >> http://svn.apache.org/viewvc/httpd/httpd/trunk/server/mpm/event/event.c?rev=1629909&r1=1629908&r2=1629909&view=diff >> ============================================================================== >> --- httpd/httpd/trunk/server/mpm/event/event.c (original) >> +++ httpd/httpd/trunk/server/mpm/event/event.c Tue Oct 7 15:16:02 2014 > if (all_dead_threads) { >> @@ -2801,12 +2800,12 @@ static void perform_idle_server_maintena >> >> retained->max_daemons_limit = last_non_dead + 1; >> >> - if (idle_thread_count > max_spare_threads/num_buckets) { >> + if (idle_thread_count > max_spare_threads / num_buckets) { >> /* Kill off one child */ >> ap_mpm_podx_signal(pod[child_bucket], AP_MPM_PODX_GRACEFUL); >> retained->idle_spawn_rate[child_bucket] = 1; >> } >> - else if (idle_thread_count < min_spare_threads/num_buckets) { >> + else if (idle_thread_count < min_spare_threads) { > > Why this?
My bad, thanks, fixed in r1629990. However I was and am 'm still confused about the way for the adminstrator to configure these directives. Should (s)he take into account the number of active CPU cores or should the MPM do that? What about existing configurations? Currently (r1629990, as per the original commit and Yingqi's proposed fixes to avoid division by 0), this is the administrator's job, but we silently raise the values if they don't feet well, this is not consistent IMHO. Wouldn't it be better, though more thread/process consuming, to always multiply the values with the number of buckets? This concerns ap_daemons_to_start, ap_daemons_limit, [min|max]_spare_threads (for unixes threaded MPMs), ap_daemons_[min|max]_free (for prefork).