I've setup our server so that each site has its own user. This seems to be the standard way to do it (and most secure).
I seem to be reaching some sort of pool limit. The php-fpm.conf file clearly says, "There is no limitation on the number of pools which FPM can handle. Your system will tell you anyway :)". However, the service will only launch a maximum of 9 pools before one silently dropped. Is this my system letting me know? (no error and plenty of spare memory).
Pools are included using the default setup (Debian): include=/etc/php/7.0/fpm/pool.d/*.conf
Basically, 9 of these will be loaded, anymore are dropped without an error. If I rename files in this folder so they are ordered differently a different 9 pools will be launched (ie. it loads the either the first or last 9 from the folder).
A sample of my pool config is:
[user1]
user = user1
group = user1
listen = /run/php/php7.0-fpm-user1.sock
listen.owner = www-data
listen.group = www-data
pm = ondemand
pm.max_children = 5
pm.start_servers = 2
pm.min_spare_servers = 1
pm.max_spare_servers = 3
pm.process_idle_timeout = 10s;
pm.max_requests = 500
env[HOSTNAME] = $HOSTNAME
env[PATH] = /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
env[TMP] = /tmp
env[TMPDIR] = /tmp
env[TEMP] = /tmp
All my pools are setup as above (with different user names of course). I have tried both ondemand and dynamic but neither work.
I have plenty of spare memory on the server so am guessing that is not the issue.
Is this a FPM bug or do I need to adjust some setting somewhere to allow more than 9 pools? I've looked through the FPM bug list and can see nothing current and do not want to post a bug if this an obvious config error. I cannot seem to find anyone else posting anywhere about similar issue.