MRatWork Forum by Mustafa Ramadhan

Sawo Project - Kloxo-MR Discussions => Kloxo-MR Development => Topic started by: fossxplorer on 2017-02-06, 11:30:51

Title: Moving away from old/deprecated mod_fastcgi module
Post by: fossxplorer on 2017-02-06, 11:30:51
@Mustafa, please switch to SetHandler (using mod_proxy_fcgi) instead of the ugly and outdates mod_fastcgi with FastCGIExternalServer "/home/kloxo/httpd/cp/aaaaa.com.0fake" -socket /opt/configs/php-fpm/sock/php-apache.sock -idle-timeout 3600 -pass-header Authorization.

With SetHandler and mod_proxy_fcgi it will look like:
<FilesMatch \.php$>
         SetHandler "proxy:fcgi://127.0.0.1:9000"
</FilesMatch>

This will work only with Apache >= 2.4, but i hope there is no need to stay at Apache 2.2 nowadays.
More info at https://blog.remirepo.net/post/2014/03/28/PHP-FPM-and-HTTPD-2.4-improvement




Title: Re: Moving away from old/deprecated mod_fastcgi module
Post by: MRatWork on 2017-02-06, 17:05:24
I am more confident using mod_fastcgi instead mod_proxy_fcgi. There are something wrong with mod_proxy_fcgi if using socket instead port.
Title: Re: Moving away from old/deprecated mod_fastcgi module
Post by: fossxplorer on 2017-02-07, 14:37:05
I understand, but it's old/deprecated and we need to move on istead of being stuck with old stuff
Should not be a problem with sockets using mod_proxy_fcgi either:
<FilesMatch \.php$>
         SetHandler "proxy:unix:/var/run/php-fpm/kloxo.sock|fcgi://localhost"
</FilesMatch>

I use this setup on other servers, no problem at all :)
Title: Re: Moving away from old/deprecated mod_fastcgi module
Post by: MRatWork on 2017-02-07, 14:44:46
Try select 'proxy_fcgi_event' instead 'php-fpm_event' for 'php-type' under 'webserver configure'.

Mod_fastcgi is not built-in plugin in apache. As I said, mod_fastcgi still better than mod_proxy_fcgi. FYI, all fastcgi under other web servers (like nginx) based on as the same as mod_fastcgi under apache.