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
3 answers

Why is the response truncated at 16k with php + fastcgi?

I've got PHP 5.3.3 and nginx 0.8.47 compiled from source running a Wordpress blog. The RSS feed generated by Wordpress was getting truncated at roughly 16k (including header was 16k+90b). By adding the following to my nginx config: fastcgi_buffers 8…
ColinM
  • 701
  • 8
  • 19
5
votes
2 answers

Nginx returning blank HTML pages with php-fpm

I'm using php-fpm through Nginx. My nginx.conf can be found here: http://pastebin.com/Nu9iD8Km It includes a file found here: http://pastebin.com/ece4cwXF My php-fpm.conf can be found here (all the options omitted are the default):…
Kudu
  • 247
  • 2
  • 4
  • 8
5
votes
1 answer

Getting correct SERVER_PORT to php-fpm through nginx and varnish

The goal is to get PHP aware of the correct web-facing server_port. The setup is: nginx on port 443 reverse proxying to varnish on port 80 reverse proxying to nginx on port 8008 and running php-fpm as a fastcgi. hitting 80 or 443 both work fine…
MDrollette
  • 325
  • 3
  • 12
5
votes
1 answer

Per pool php.ini on php-fpm

Anyone have any idea how to do this in tittle ? Or at least something similar (enable/disable functions that are usualy in php.ini) My pool now looks like this [amar] listen = 127.0.0.1:11000 user = amar group = amar request_slowlog_timeout =…
amarc
  • 173
  • 3
  • 8
5
votes
1 answer

"upstream sent too big header while reading response header from upstream" error - Increasing buffers not working

I've set up the Bitnami Nginx Open Source Stack at AWS. I've started creating an application using auth0 as my authentication service. After successful login, the code must be exchanged for an access token. This is done using…
aanders77
  • 151
  • 3
5
votes
1 answer

Syntax of Apache SetHandler directive when configuring PHP FPM

I've followed a couple of tutorials and configured Apache to use PHP FPM. However, I do not understand what part of the SetHandler line is doing and based on some of my experiments appears to be redundant. I have the line: SetHandler…
Dom
  • 458
  • 1
  • 5
  • 15
5
votes
1 answer

PHP status page not working in Apache

Using PHP7.3 FPM along with Apache 2.4.25 I have a problem when enabling PHP FPM status page. What is working: # /etc/php/7.3/fpm/pool.d/www.conf listen = /run/php/php7.3-fpm.sock pm.status_path = /status-php #…
rabudde
  • 304
  • 5
  • 22
5
votes
0 answers

PHP-FPM: pm.process_idle_timeout for PM = static or dynamic

I'm working with CentOS 8 and PHP-FPM setting for PM = static or dynamic does not allow an option for pm.process_idle_timeout. ; The number of seconds after which an idle process will be killed. ; Note: Used only when pm is set to 'ondemand' ;…
Bernard K.
  • 61
  • 5
4
votes
1 answer

PHP-FPM creating too many proccesses & eating all the CPU

This is an urgent question. My AWS instance with 4GB RAM and 2vCPU is getting exhausted by too many php-fpm processes. PHP-FPM starts creating too many processes which it didn't do earlier. This results in slow loading of the site. I'm not able to…
Axel
  • 421
  • 2
  • 8
  • 18
4
votes
1 answer

Low CPU Utilisation But High CPU Load Wordpress Ubuntu Apache2

My Ubuntu 18.04 server with 2GB of RAM and 2 CPU cores experiences major CPU load spikes when someone accesses the Wordpress site that the computer serves. This slows down the website very much. Below is the output from a top command In the…
SidS
  • 145
  • 5
4
votes
0 answers

Why Does PHP-FPM sometimes get stuck serving old files?

I have some very simple Ubuntu server setups with NGINX passing requests for PHP files via PHP-FPM. However, on two different servers, I've had the situation where http requests from browsers are being served old versions of the PHP files, missing…
Ambulare
  • 141
  • 4
4
votes
2 answers

How to Remove php-fpm for mod-php

We have a site that's performing very slowly. I have a suspicion that it's php-fpm configs, but rather than play with it if it's not the issue, I want to do performance tests first. So I cloned one of our load balancer production VMs and want to…
Aaron Chamberlain
  • 381
  • 1
  • 3
  • 13
4
votes
1 answer

Nginx says 404 not found, no error log

I am getting a 404 not found at nginx page, i get no error in nginx error log file too. server { listen 6269; server_name (domain); root /home/temp; index /_h5ai/public/index.php; location / { try_files $uri $uri/…
Sid
  • 63
  • 1
  • 1
  • 4
4
votes
1 answer

What does "graceful reload" actually mean with php fpm?

The php-fpm man page states the response to a USR2 signal is: "graceful reload of all workers + reload of fpm conf/binary". However, in testing I find that a reload actually kills workers processing requests. I was expecting requests to be allowed…
virullius
  • 1,048
  • 1
  • 9
  • 23
4
votes
1 answer

Nginx and PHP-FPM concurrent requests from same IP

I am having trouble serving concurrent time consuming requests coming from the same IP. First request should take 6 minutes to respond (this is normal behaviour, my question is not about taking less time to respond) Second request should take…
Hammerbot
  • 175
  • 2
  • 8