Questions tagged [php-fpm]

PHP-FPM (FastCGI Process Manager) is an alternative PHP FastCGI implementation with some additional features useful for sites of any size, especially busier sites.

PHP-FPM provides a number of useful features over the traditional FastCGI php implementation. It is implemented as a daemon that controls one or more PHP process 'pools' which can be independently configured. Main configuration options for each pool include:

  • Socket on which requests are received (either local or TCP)
  • Separate php.ini settings for specific application requirements
  • Dynamic process control. FPM can dynamically change the number of worker processes depending on pool load.
  • Uid/gid for the pool workers
  • In-flight configuration updates - a change to the pool configuration will be rolled out gracefully across all pool workers without losing connections.
2118 questions
5
votes
1 answer

Apache 2.4 with PHP-FPM .htaccess redirection

I have Apache 2.4 set up with PHP-FPM on a server. To pass from Apache to PHP-FPM I use the following: ProxyPassMatch ^/(.*\.php)$ fcgi://127.0.0.1:9001/hosting_files/site.com/admin_secure/$1 "admin_secure" is the DocumentRoot in the vhost. In…
nwalke
  • 643
  • 2
  • 12
  • 32
5
votes
4 answers

How do I enable PHP’s flush() with nginx+PHP-FPM?

I’m using nginx with PHP-FPM (APC is installed). I need PHP’s flush() to work. Is this possible? Things I’ve tried so far: Disabling all output buffering in php.ini, as well as output compression. Disabling gzip in nginx’s configuration. Setting…
Abraham Vegh
  • 1,045
  • 5
  • 17
  • 26
5
votes
1 answer

Best way to set up permissions with nginx + php-fpm on shared hosting?

I'm running a shared hosting server with nginx and php-fpm on Debian. Everything works fine, php-fpm has separate pools for each users running as separate users and they each have their own socks. Nginx is however running as www-data because I don't…
dBi
  • 75
  • 2
  • 4
5
votes
1 answer

Where can I find a PHP-FPM RC script?

I compiled PHP on my own computer, and I want to know how to setup a script to start PHP-FPM automatically. Can anyone suggest a script that will do this for me? I'm using a Ubuntu Linux server install.
Mark Tomlin
  • 650
  • 3
  • 10
  • 23
5
votes
2 answers

A complicated nginx/php-fpm chroot setup

I'm running nginx and php-fpm, and I want to set up jails for each host. My setup is a little complicated, so following tutorials on the web gets me nowhere. Each site has a directory /var/www/domain.name/ Inside that directory, there will be a…
Rsaesha
  • 360
  • 3
  • 11
5
votes
1 answer

What is difference of PHP handler (CGI vs FastCGI vs Mod_PHP vs suPHP )?

I understand that there are four different PHP handlers out there (AFAIK). CGI (php-cgi) FastCGI (php-fpm) Mod_PHP suPHP I need to know the pros and cons of these handler and what environments each are suited for? For example if I'm running a…
2hamed
  • 479
  • 1
  • 5
  • 23
5
votes
2 answers

PHP-FPM signals for pool error_log rotation

I am moving all my server's log rotation tasks for logrotate. The server has several PHP-FPM pools, each of them configured with a separated error_log directive. The logrotate recipe for the logs is fairly simple: /var/log/php/*.log { rotate…
Ville Mattila
  • 459
  • 7
  • 13
5
votes
1 answer

Using a mounted NTFS share with nginx

I have set up a local testing VM with Ubuntu Server 12.04 LTS and the LEMP stack. It's kind of an unconventional setup because instead of having all my PHP scripts on the local machine, I've mounted an NTFS share as the document root because I do my…
Hoff
  • 181
  • 1
  • 8
5
votes
2 answers

Graceful upgrade from php53u to php54

We are running a CentOS 6 node using iuscommunity repo, and want to upgrade previously installed php53u to php54. However, this introduces a dependency conflict between php53u & php54. Does anyone have idea for this problem? --> Running transaction…
sparanoid
  • 205
  • 3
  • 7
5
votes
2 answers

Phpmyadmin location for nginx

I installed nginx and phpmyadmin. I set up a domain with these parameters to test phpmyadmin: server { listen 80; server_name example.com; root /usr/share/phpmyadmin; index index.php; fastcgi_index index.php; location ~ \.php$ { include…
MultiformeIngegno
  • 1,687
  • 9
  • 26
  • 31
5
votes
2 answers

Disable FastCGI Read Timeout in Nginx?

Is there a way to disable the read timeout for FastCGI? (fastcgi_read_timeout) Setting it to zero does not work and just causes an immediate timeout. Nginx 1.0.5 PHP-FPM 5.3.6-13ubuntu3.6 The reason I need to get around the timeout is because of…
Kevin Herrera
  • 175
  • 1
  • 5
5
votes
2 answers

Denying folder in Nginx causing PHP-FPM to not take precedence

The title says it all, but I have a very interesting problem that I am quite confused on. Basically, I have a simple WordPress installation, and I wish to deny a folder (along with all files in the folder), let's say…
Taylor Jasko
  • 696
  • 4
  • 13
5
votes
1 answer

php-fpm status page: what are the "queue" items in this report?

So I have a working nginx+php-fpm installation. The php-fpm status report page is activated and I get something like that (do not care about settings, it's a test server under stress tests): pool: foobar process manager: …
regilero
  • 1,480
  • 1
  • 9
  • 14
5
votes
2 answers

Optimize php-fpm and varnish for a powerful server

My setup is Intel® Core™ i7-2600 and RAM 16 GB DDR3 RAM varnish+nginx+php-fpm+apc for a not very heavy WordPress blog with W3 Total Cache and CDN My problem is that after 55 hits per second according to blitz.io varnish starts giving out timeouts.…
Jim
  • 410
  • 4
  • 14
5
votes
2 answers

Nginx + PHP-FPM Timeouts, almost zero load consumption?

I've got a server running on a Linode with Ubuntu 10.04 LTS, Nginx 0.7.65, MySQL 5.1.41 and PHP 5.3.2 with PHP-FPM. There is a WordPress blog on it, updated to WordPress 3.2.1 recently. I have made no changes to the server (except updating…
javipas
  • 1,332
  • 3
  • 23
  • 38