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
6
votes
4 answers

Need help trouble shooting high CPU usage by PHP-fpm

There is a problem that is driving me crazy. After the day I tried to fix the CPU usage problem of my VPS, the CPU load has grown from 60% to 150%, and I have no idea what causes the problem. Please help me. I had installed a copy of mediawiki on a…
yang
  • 161
  • 1
  • 1
  • 4
6
votes
3 answers

nginx not able to connect to php-fpm socket

I setup a system similar to the tutorial here. I'm having issues with nginx connecting to the php5-fpm socket, but from what I can tell the permissions on the socket are correct... can you give me a hand? 2011/04/14 15:31:24 [crit] 13147#0: *1…
zeroasterisk
  • 275
  • 1
  • 4
  • 10
6
votes
4 answers

Nginx + PHP 5.3.3 (with php-fpm) - memory usage?

I recently bought Xen VPS (linode.com) with Debian 5.0 Lenny (i386), 512MB RAM. At the moment I have only three small websites (built with Drupal) with about 600 users per day in total running on this server. As a web server I use nginx 0.7.67 (PHP…
user38484
  • 313
  • 2
  • 5
  • 10
6
votes
3 answers

How to disable PHP-FPM request logging?

I keep seeing logs like these in my Kubernetes cluster: [php] - - 05/Jul/2020:20:15:55 +0000 "POST /api/bookings" 200 How can I disable them? If PHP wants to write an error or something, I want to keep that, it's just the request logs I don't care…
mpen
  • 423
  • 1
  • 6
  • 15
5
votes
1 answer

listen.owner & listen.group not taken into account

I'm trying to change the owner/group of the PHP-FPM socket file. My www.conf contains: [www] ... listen = /run/php-fpm/www.sock listen.owner = ben listen.group = ben listen.mode = 0660 Upon restarting php-fpm, www.sock is still owned by…
BenMorel
  • 4,507
  • 10
  • 57
  • 85
5
votes
1 answer

Apache PHP-FPM weird responses with Proxy enablereuse=on

When enabling I start receiving strange responses. When refreshing the current page, the main request loads different responses; like a blank page, responses intended for a separate client, or a 404 response from a…
Will B.
  • 73
  • 8
5
votes
3 answers

How to set date.timezone and what is the correct place to do it

(I'm trying to deploy an open source php project to nginx. The project itself does not matter.) I need to set date.timezone to my local timezone because the project uses a global setting. I found a line in my php.ini (at /etc/php/7.0/fpm/php.ini…
nosh
  • 153
  • 1
  • 1
  • 4
5
votes
6 answers

PHP-FPM - Error 503 - Attempt to connect to Unix domain socket failed

I get on server this errors (CentOs 7): [proxy:debug] proxy_util.c(2209): [client 80.251.245.153:61902] AH00944: connecting fcgi://127.0.0.1/data/webs/dev/index.php to 127.0.0.1:8000 [proxy:debug] proxy_util.c(2246): [client 80.251.245.153:61902]…
Pavel Novák
  • 51
  • 1
  • 1
  • 3
5
votes
2 answers

How to test php-fpm configuration (PHP7.0)

I am running a webserver with Ubuntu 16 and php-fpm to process PHP requests. php-fpm has been installed via apt-get from the default Ubuntu repositories. According to this reference I should be able to run php-fpm -t to test the configuration.…
BurninLeo
  • 900
  • 3
  • 12
  • 30
5
votes
2 answers

Nginx With PHP FPM - Resource Temporarily Unavailable - 502 Error

Nginx With PHP FPM - Resource Temporarily Unavailable - 502 Error I am using a some code to send off just over 160 GET requests asynchronously using curl to my API which is running Nginx with Php-fpm on Ubuntu server 16.04. Each request fetches a…
Programster
  • 495
  • 1
  • 13
  • 22
5
votes
1 answer

Nginx + PHP-FPM URI alias and multiple php directories

I am trying to configure Nginx to host multiple PHP based apps in two different directories in the same domain. The outcome I'm trying to get to is: http://webserver.local/ > app served from /path/to/website http://webserver.local/app > app served…
cpjones44
  • 160
  • 2
  • 8
5
votes
1 answer

nginx logs php-fpm's stderr output cut off at seemingly random positions

Ever since I started using a PHP library that produces a long call chain it's been increasingly difficult to debug issues caused by it because my error logs end up containing output like this: (some values have been blanked out using *) 2017/08/23…
SeinopSys
  • 532
  • 2
  • 6
  • 19
5
votes
1 answer

Nginx not serving CSS correctly in simple PHP project

I've seen several examples of this now: Resource interpreted as Stylesheet but transferred with MIME type text/html: "http://localhost:3001/assets/css/bootstrap.min.css". But, I've not been able to understand what might be causing it. The CSS files…
ankush981
  • 257
  • 2
  • 4
  • 11
5
votes
1 answer

How to disable abbreviated SSL handshake to perform a full handshake every call on lighttpd?

I understand the ssl handshake flow, but I'm facing a logic problem. When a user selects a certificate I need to validate it against application to know that its reliable and match with any system user. But if not, I must allow for user ask again to…
LeonanCarvalho
  • 640
  • 2
  • 6
  • 22
5
votes
1 answer

Wordpress, nginx, php-fpm: XML-RPC not working

I've installed Wordpress with Nginx and PHP-FPM on my own server at https://saskia.photo The installation works great but the XML-RPC (used by Jetpack and the phone apps) throws the following error:
Leonard Ehrenfried
  • 371
  • 1
  • 3
  • 8