I’m in the process of switching Apache from mpm-prefork to mpm-event and php-fpm.
I’m using mpm-event & php-fpm on my outgoing server - the main difference being that the old server is using TCP ports for php-fpm (one for each domain\Virtual Server) and for the newly built one, I’m looking at using sockets.
[along with one php-fpm pool per domain\Virtual Server].
I can manually set Apache\PHP up to do this - but is there anyway I can do this via Virtualmin, so that each time I create a new Virtual Server\domain in Virtualmin - the correct entry for the user specific socket gets created in the domain\user conf file in /etc/php/7.x/fpm/pool.d directory?
Execution mode is there and that can\will be changed but my understanding is that that doesn’t give you the choice between sockets and ports.
Basically I’m wanting a pool per user\domain\Virtual Server - Virtualmin will do that but I’m wanting a socket per pool, not a port per pool. if that makes sense?
No, Virtualmin doesn’t support a use of sockets for PHP-FPM, in favor of using ports. There is nothing wrong in using ports for PHP-FPM processes and upcoming Virtualmin 6.10 will also have a configurable option to set base port number for FPM servers:
I was just configuring\optimizing Apache, PHP & MySQL (yet to do). For me that means switching Apache to mpm-event, moving to php-fpm (using 1 pool per user\domain) and not got round to looking what I did to MySQL on the existing server.
From what I’ve read sockets to perform (somewhat) better, but it’s not the end of the earth using ports.