I was mid-switching to a ubuntu 16.04 LTS server when 5.0.6 came out: I have been waiting with bated breath for php-fpm support.
I am running with apache2.4.18 with the native php packages from ubuntu, and virtualmin pro build 1.831.
I noticed a few things right away:
at first, the fpm configuration was not set up with the ssl site.
This may have been resolved as I saw a webmin/virtualmin update come in since the 16th. Either way, this problem went away.
upon re-installation from scratch, none of the php-fpm packages were installed, nor was apache configured to run fpm
I installed the packages by hand (apt-get install php-fpm)
a2enmod proxy proxy_fcgi
the /var/php-fpm directory was not created
I had to create by hand
the unix socket was created as /var/php-fpm/14878750116127.sock, but with the following permissions:
srw-rw---- 1 root root 0 Feb 23 10:37 14878750116127.sock
In other words, it’s not even accessible by user www-data, or the virtual server user.
But having said that,
- Apache shows “service unavailable” with the apache logs showing:
[Thu Feb 23 13:55:20.593748 2017] [proxy:error] [pid 9132] (111)Connection refused: AH00957: FCGI: attempt to connect to 127.0.0.1:8000 (*) failed
[Thu Feb 23 13:55:20.593800 2017] [proxy_fcgi:error] [pid 9132] [client 22.214.171.124:49789] AH01079: failed to make connection to backend: localhost
Note that proxy_fcgi is trying to connect to 127.0.0.1:8000, but that’s not defined anywhere. This makes me think this is some sort of apache default, but either way it’s ignoring the actual handler stanza of:
ProxyPassMatch ^/(.*.php(/.*)?)$ unix:/var/php-fpm/14878750116127.sock|fcgi://localhost/home/jasontest2/public_html/$1
As far as I can tell, it’s not even trying to use that socket.
For what it’s worth, this was all done with mod_php, and mpm-prefork mode. This exact same problem occurs with changing to mpm-worker, removing mod_php, and mod_fcgid.
Thank you for your time!