Re: Two questions on httpd tuning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Luca,


On Fri, Aug 18, 2017 at 9:01 AM, Luca Toscano <toscano.luca@xxxxxxxxx> wrote:
Hi Martin,

2017-08-17 17:40 GMT+02:00 Martin Knoblauch <knobi@xxxxxxxxxxxx>:
Hi,

 this is for httpd-2.4.26 with the mpm_worker_module. I have one practical and one more theoretical question.

First, is there a way to determine the maximum number of concurrent requests that have been processed at any time since the last server (re)start?

I would periodically poll https://httpd.apache.org/docs/2.4/mod/mod_status.html and push metrics to a backend like graphite/prometheus/etc.  

 OK. Clearly one way of doing it. Thanks.


 

Second, if I have the default configuration and I ever want to increase MaxRequestWorkers above 400 my understanding is that I need to either increase ServerLimit or ThreadsPerChild (or adjust both). Which should I touch first (why :-)?


"ServerLimit is a hard limit on the number of active child processes, and must be greater than or equal to the MaxRequestWorkers directive divided by the ThreadsPerChild directive."

Basically mpm_worker creates some processes (maximum ServerLimit) that in turn spawn ThreadsPerChild threads each, so you need to tune them to reach MaxRequestWorkers.

Hope that helps :)
 
 Not on the second one. sorry :-)

 Lets say I wanted to increase MaxRequestWorkers to e.g. 800. One of the several solutions would be to up ServerLimit to 32 and leave ThreadsPerChild at 25. But I could also leave ServerLimit at 16 and up ThreadsPerChild to 50. Or I could choose any combination where ServerLimit*ThreadsPerChild is bigger than 800. What I would like to know is which way to go. And why. What gives the best and most reliable results. Assumption is that there is plenty of free memory, CPU and network bandwidth available.

Cheers
Martin

--
------------------------------------------------------
Martin Knoblauch
email: k n o b i AT knobisoft DOT de
www: http://www.knobisoft.de

[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux