Discussion:
why apache create child process one more than startservers config parameter?
(too old to reply)
Jeff
2022-09-08 03:29:34 UTC
Permalink
why apache create child process one more than startservers config parameter?

* http-mpm.conf (worker)
StartServers 5

* Real Process count(ps -ef httpd)
Parrent 1
Child 6 (one more than 'StartServers 5')
Eli the Bearded
2022-09-08 05:00:21 UTC
Permalink
Post by Jeff
why apache create child process one more than
startservers config parameter?
* http-mpm.conf (worker)
StartServers 5
* Real Process count(ps -ef httpd)
Parrent 1
Child 6 (one more than 'StartServers 5')
StartServers is not a maximum, it's a hint for expected load at startup.

MinSpareServers and MaxSpareServers influence the number of processes by
controlling how many idle children to have.

MaxRequestWorkers (aka MaxClients) is the hard cap on the number of
processes.

https://httpd.apache.org/docs/2.4/mod/mpm_common.html
https://httpd.apache.org/docs/2.4/mod/prefork.html

Elijah
------
four spare is a good config on a tiny vm
Jeff
2022-09-08 06:13:36 UTC
Permalink
Post by Eli the Bearded
Post by Jeff
why apache create child process one more than
startservers config parameter?
* http-mpm.conf (worker)
StartServers 5
* Real Process count(ps -ef httpd)
Parrent 1
Child 6 (one more than 'StartServers 5')
StartServers is not a maximum, it's a hint for expected load at startup.
MinSpareServers and MaxSpareServers influence the number of processes by
controlling how many idle children to have.
MaxRequestWorkers (aka MaxClients) is the hard cap on the number of
processes.
https://httpd.apache.org/docs/2.4/mod/mpm_common.html
https://httpd.apache.org/docs/2.4/mod/prefork.html
Elijah
------
four spare is a good config on a tiny vm
The one httpd was cgi daemon.

# pstack 57676
#0 0x000000387620eb10 in __accept_nocancel () from /lib64/libpthread.so.0
#1 0x00007fde96fd7bae in cgid_server () from /usr/local/apachesso/modules/mod_cgid.so
#2 0x00007fde96fd89b4 in cgid_start () from /usr/local/apachesso/modules/mod_cgid.so
#3 0x00007fde96fd8ad0 in cgid_init () from /usr/local/apachesso/modules/mod_cgid.so
#4 0x00000000004581c9 in ap_run_post_config ()
#5 0x0000000000430d59 in main ()

Thanks.

Loading...