Why does one LSAPI CHILD take around 120MB of RAM?

#1
I was playing around with PHP_LSAPI_CHILDREN and LSAPI_AVOID_FORK and also memory limits and noticed that a hard limit of under 300MB of ram makes the server not really come up again. And the only way I can limit the total RAM of OLS from my understanding now is to limit the number of PHP_LSAPI_CHILDREN. And after increasing RAM on my container I noticed that the Children always take around 120MB of RAM.

Am I missing something in the docs? What is the best practice or most reliable way to control OLS (PHP) memory usage in total?
 

Cold-Egg

Administrator
#2
It might be controlled by the memory_limit setting in your php.ini file. Have you checked the phpinfo page to see what value is set for memory_limit?
 
#3
It might be controlled by the memory_limit setting in your php.ini file. Have you checked the phpinfo page to see what value is set for memory_limit?
The info page shows that the value set in the php.ini file is being respected. I changed that value a few times to test your theory, but no matter what value, high or low, the PHP_LSAPI_CHILDREN show around 100-125MB RAM usage.

So if I want to change total memory consumption of PHP I need to calculate with 120MB it seems per CHILD.
Is there any more official/reliable way to control total consumption?

Would be nice if one could set total PHP consumption and OLS would spawn children according to that by itself.
 
Top