• Debian 11 is approaching its end-of-life (vendor EOL date - August 31, 2026). Plesk Obsidian 18.0.80 will be the last release to support it.
    If you are running Plesk Obsidian on Debian 11, we recommend you upgrade those servers to Debian 12 using our dist-upgrade tool.
  • We plan to deprecate and remove the support for XML RPC protocol versions earlier than 1.6.9.1 in Plesk Obsidian 18.0.82. We strongly recommend that you update all existing integrations using earlier versions of the XML RPC protocol to comply with the version 1.6.9.1 specification.

Modifying php-fpm settings for all domains and new ones?

Some sites reach maximum children

so I need to change

pm.max_children = 5

for all new domains on a server

How can this be done?

I know i can change it manually on each new domain, is there some kind of template to modify?
 
Use "sed", if you want to change such things... and to avoid Plesk re-changing the modified conf - files, please rename them to something I suggest as well:

Code:
sed -i 's/pm.max_children = X/pm.max_children = XX/' /etc/php5/fpm/pool.d/*.conf
sed -i 's/pm.start_servers = X/pm.start_servers = XX/' /etc/php5/fpm/pool.d/*.conf
sed -i 's/pm.min_spare_servers = X/pm.min_spare_servers = XX/' /etc/php5/fpm/pool.d/*.conf
sed -i 's/pm.max_spare_servers = X/pm.max_spare_servers = XX/' /etc/php5/fpm/pool.d/*.conf
sed -i 's/;pm.max_requests = X/pm.max_requests = 1024/' /etc/php5/fpm/pool.d/*.conf

( optional - if set... if not set yet, you might think of using it, to tune your several php-fpm - configs! )
sed -i 's/;rlimit_files = X/rlimit_files = 102400/' /etc/php5/fpm/pool.d/*.conf

Please replace the "X" with YOUR actual and desired definitions!

To rename the config - files, please use:

rename s/'^'/'YOUR_PREFIX'/ /etc/php5/fpm/pool.d/*
 
Back
Top