FastCGI vs PHP-FPM Settings

Discussion in 'Installation/Configuration' started by jaypabs, Jun 14, 2013.

  1. jaypabs

    jaypabs New Member

    Since I am new to ISPConfig, I am exploring around at the Sites >> Web Domain >> Options and found out there is a settings for "Use Socket For PHP-FPM" which is set to false by default.

    I believe that when it is set to false, it is using FastCgi, but when set to true, it is using PHP-FPM. So my question is which is better between this two? FastCGI vs PHP-FPM?
     
  2. jaypabs

    jaypabs New Member

    Anybody with experience between the two? Which is better and which is faster? FastCGI or PHP-FPM?
     
  3. till

    till Super Moderator Staff Member ISPConfig Developer

    No, thats not the case. When it is set to false and you selecetd php-fpm as php mode, then php will communicate with apache over a tcp port, if it is set to true, a socket will be used instead.

    php-fpm is a modern reimplementation of the php fastcgi interface, it offers more config options and might be a bit faster then fastcgi.
     
  4. jaypabs

    jaypabs New Member

    Thanks for the reply.

    When it is uncheck the value in the vhost file is this:

    fastcgi_pass 127.0.0.1:9019;

    When it is check the value is something like this:

    fastcgi_pass unix:/var/lib/php5-fpm/web9.sock;

    Is this means that I am still using PHP-FPM? If yes, what is the difference between the two? And which one is better?

    And how to I know if I am using php-fpm as php mode?

    Thanks. I will using php-fpm in this case.
     
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    yes.

    I described that above.

    I woul use sockets.

    You can see that in the phpinfo() output.
     
  6. jaypabs

    jaypabs New Member

    So, why ISPConfig not using the socket by default?

    Here's some output of the phpinfo(). I'm putting it here coz I'm confuse if I am using php-fpm or fastcgi:

    [​IMG]
    [​IMG]
     
  7. till

    till Super Moderator Staff Member ISPConfig Developer

    Because the ports version always works while the socket version might fail depending on the individual server configuration. Also the difference is very small, you might notice it only on very large sites with several hundred thousand pageviews a day.

    PHP FPM.
     

Share This Page