Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
Join us in building a kind, collaborative learning community via our updated Code of Conduct.

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.

0
votes
0answers
16 views

Deploying a php/laravel app with nginx in Docker swarm yields blank page and no errors

I have a Laravel application which I plan to deploy on a Docker Swarm. The problem is that no matter what I do I get a blank page when calling localhost/index.php. I'm using 2 separate services for: ...
0
votes
0answers
197 views

Can't get PHP to parse with NGINX/FastCGI/PHP

So I spent the better part of last night trying to get my ec2 instance setup with nginx and php7.2. I got everything installed and I edited the server block in my nginx.conf with the values I thought ...
0
votes
1answer
38 views

Moodle: Error during Installation

I am trying to install Moodle and everything seems fine but then when it comes to Admin user creation process, it seems as there is no CSS file, and "update profile" button does not perform any action....
0
votes
0answers
15 views

PHP for redis not loading

Trying to get REDIS client installed correctly for use on a debian linux install. I installed redis client with PECL. When I run PHP -m from the command line it shows that the redis client is loaded ...
1
vote
1answer
20 views

PHP-FPM and PHP execution yields different results

I have used a docker container with the embedded php server for development. Now we are creating a test environment and we wanted to use php-fpm. Everything went fine and the whole thing works as ...
0
votes
1answer
28 views

Nginx downloads php files in subdirectories

I've searched all over the internet and read all questions and answers and tried them all but no help. The problem is, whenever I try loading a php file using nginx in any subdirectory it downloads ...
0
votes
0answers
12 views

nginx, php7.0-fpm and laravel, not able to set it up when the url has a prefix which the server doesn't have

I am trying to set up a laravel installation in docker with php-fpm and nginx server on a separate container. The issue is the laravel is installed in a path like /home/apps/foo and the url I need is ...
-2
votes
0answers
33 views

nginx error! - The page you are looking for is temporarily unavailable. Please try again later

I set up LEMP, I set up nginx on a serverA and set up php-fpm on serverB serverB has a mount point from Glusterfs server, the glusterfs server is synced with ServerA ON SERVER A http directive in ...
0
votes
2answers
32 views

nginx server redirecting to 2 different containers based on path for laravel

I am trying to do the following: I have 2 docker php-fpm(no nginx) containers with the same directory structure but with different versions of code. Now I have another container with nginx in it. ...
0
votes
1answer
41 views

php memory_limit vs kubernetes resource memory limit

I'm new to Kubernetes and I'm trying to figure out what resource limits I should set for my php webapp. My first guess is that if I have configured php fpm to use a maximum of 256M of memory then ...
0
votes
0answers
23 views

Apache 2.4 with php-fpm ignores .htaccess

I have a VPS server with Apache, FastCGI and php-fpm installed. But, the .htaccess files seems be ignored. I have a .htaccess file that redirects http URLs to https URLs: <IfModule mod_rewrite.c&...
0
votes
0answers
31 views

trouble with installing fastcgi_cache_purge ubuntu 16.04

So I'm trying to install fastcgi_cache_purge which is supposely a third party module https://github.com/FRiCKLE/ngx_cache_purge from https://www.nginx.com/resources/wiki/modules/ but this would ...
0
votes
1answer
48 views

Apache 2.4 with PHP-FPM 5.6 on Centos 6

I'm trying to get PHP working over FPM on Centos. On the FPM side, /etc/php-fpm.d/www.conf is pretty much the default values. I'm left it using a TCP port as follows (I may want to change to a file ...
0
votes
0answers
25 views

High CPU blocking performance on SSH tunnel with PHP-FPM

I've a Debian 9 VPS set up with Apache and PHP-FPM. It connects to another VPS to access a common database server VPS via an SSH tunnel. Mostly this works fine. Running a test for broken links ...
1
vote
1answer
63 views

nginx + php5-fpm: Resource temporarily unavailable

I have an nginx (in a Debian docker container) with this config for a Symfony app: location ~ ^/api/(app|app_dev|config)\.php(/|$) { root /var/www/backend/web/; fastcgi_split_path_info ^/api/(...
0
votes
1answer
41 views

Nginx/php-fpm timeouts

I have a setup that consists of a load balancer, two web servers running nginx/php-fpm7.1 and a database server running mariadb. For the past few months I have been struggling to work out the cause ...
0
votes
0answers
78 views

504 Gateway Time-out Nginx -> PHP-FPM kubernetes

I've been trying to get my nginx connection to work with php-fpm for several days now. The problem is, he always gives me a 504 and gives me the next error log: 2018/07/09 10:57:25 [error] 5#5: *10 ...
0
votes
0answers
21 views

php-fpm cannot acess unix socket

I'm using different PHP-FPM pools with specific users each one. I just switched memcached to use a socket instead of tcp/udp ports (for many reasons including the recent attacks on the 11211 port). I’...
0
votes
1answer
180 views

NGINX+PHP-FPM7 FastCGI sent in stderr: “Primary script unknown”

Can't get it work. I've been reading the forums and trying here and there. It's a fresh installation on AWS Linux2 AMI (redhat based), installed wordpress at /var/www/wordpress, set permissions, have ...
0
votes
0answers
8 views

FPM/FastCGI where to change the max execution time for scripts

First of all i created a stack with easyengine.io on hosted on Google Cloud => Compute Engine (VM Instance) I am running FPM/FastCGI. Can somebody tell me where to change the max execution time for ...
0
votes
0answers
49 views

Nginx not executing PHP file, but executes others (shared config)

Now I know this is a common question, but I can't seem to get Nginx to execute a php file. What's funny, however, is that I'm including a common php config that works just fine for other sites/files (...
1
vote
1answer
2k views

Nginx and php-fpm wait to finish previous requests when 6+ concurrent connections

I can't figure out how to setup Nginx and php-fpm to allow more than 6 concurrent connections from single IP. I have the following simple PHP files (no FW): <?php // long-request.php sleep(15); --...
0
votes
0answers
99 views

Nginx + PhpFpm + phpmyadmin upstream timed out (110: Connection timed out) and recv() failed (104: Connection reset by peer) errors

I am having connection timed out and connection reset by peer error 503 on Nginx + Phpfpm 7.1 setup. 2018/06/28 14:32:13 [error] 2428#2428: *45 upstream timed out (110: Connection timed out) while ...
0
votes
0answers
11 views

server resource impact for using a setup with php extensions per php-fpm pool

First a bit of context: I'm running a webhosting server based on nginx with php-fpm and generally 3 flavours of php (7.0/7.1 and 7.2, disabled 5.6 since a couple of days as it wasn't used on any of ...
0
votes
0answers
18 views

URL Parameters do not appear in PHP info under Query_String

There is an issue on my server at the moment where I input: http://example.com/phpinfo.php?test=1 On the PHP Variables, it should appear with "test=1" beside "_SERVER["QUERY_STRING"]". The server ...
0
votes
1answer
189 views

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 ...
0
votes
1answer
50 views

php-fpm ignores file .user.ini

I have the following file .user.ini in /var/www/html/nextcloud upload_max_filesize=511M post_max_size=511M memory_limit=512M mbstring.func_overload=0 always_populate_raw_post_data=-1 default_charset='...
1
vote
0answers
50 views

php.net discourages the use of threaded MPM in production with Apache 2

php.net discourages the use of threaded MPM in production with Apache 2. Use the prefork MPM, which is the default MPM with Apache 2.0 and 2.2. It doesn't mention anything about apache 2.4, I ...
0
votes
0answers
19 views

Lots of ENOENT (no such file or directory) errors in my php-fpm: pool www processes, resulting in 100% processor usage

I am running a Magento 2.2.4 installation on php 7 and apache2. I have asked this on the Magento stackexchange as well but someoone suggested it might not be a magento-specific problem. Sometimes ...
0
votes
1answer
80 views

Nginx Try_files redirection losing query string

I am trying to setup a specific redirection to force redirection to index.php (for Laravel) for a specific subdirectory, bypassing existing index.html. The url i want to catch looks like this app/kit/...
2
votes
2answers
229 views

Getting environment variables in PHP-FPM with Nginx

I've defined some environment variables like APP_ENV in my /etc/environment file, on my ArchLinux. If I type printenv, I see them. I've created this simple test file called… test.php <?php ...
0
votes
1answer
46 views

1 bad phpfpm pool.d config causes disaster

I noticed that if a pool config in pool.d has a bad path, then all the pools won't start when doing systemctl start php7.0-fpm.service - is there a way to make phpfpm gracefully continue? I've tried ...
0
votes
0answers
709 views

PHP FPM pool www - 100% spikes when executing scripts - how to debug

I am experiencing weird 100% spikes of cpu when loading drupal pages. It started several months ago and now Im trying to debug this. I moved same database and files to new hosting - everything runs ...
0
votes
0answers
8 views

phpfpm won't start if 1 pool fails

My phpfpm service (using systemctl on ubuntu xenial) will NOT start ANY pools if only 1 pool is bad. Say I have 100 pool configs in /etc/php/7.0/fpm/pool.d and just one has a weird/bad path that doesn'...
0
votes
0answers
145 views

PHP-FPM 7.1 not accepting config parameters in Docker

I am getting this error on the end of php-fpm container initialization. This one and another with upload_max_filesize as unknown entry. [04-Jun-2018 13:07:59] ERROR: [/usr/local/etc/php-fpm.d/zz-...
0
votes
0answers
90 views

The main reason for random 502 and 504 errors within PHP-FPM and NGINX setup

I am just trying to find the deeper underlying issue of 502 and 504 errors I am getting and the solution. I am running ab -n 10000 -c 1000 http://172.18.0.1/ command to send 10000 requests with a ...
0
votes
0answers
235 views

Apache2 - default php7.2-fpm.conf has to be included in every virtual host?

I'm trying to move from mod_php to php-fpm using mod_proxy_fcgi. After installing the needed modules I tried following the notice I got during install: Not enabling PHP 7.2 FPM by default. ...
0
votes
0answers
33 views

How can I force fastcgi / php-fpm to refuse connections once it reaches it's capacity?

I'm trying to figure out how to refuse / return a HTTP failure response if the php-fpm reaches it's maximum concurrent requests. I've set listen.backlog to 0, however this still seems to 'queue' ...
0
votes
2answers
771 views

AH01071: Got error 'Primary script unknown

Debian Linux 8.10, Apache version 2.4.10, FPM/FastCGI. I have created a 1st virtual host. After hours, I could get it working. Then I have created another virtual host, with almost the same config =...
3
votes
1answer
403 views

Howto return 502 error code instead of 404 when PHP-FPM fails

My server configuration looks like this: Nginx1 (proxycache) <---------> Nginx2 <-> PHP-FPM When PHP-FPM fails because of the process is down ( errorconnect to unix:/run/php/php7.0-fpm.sock ...
0
votes
0answers
39 views

Http connection sometimes fails to reach (?) server while ICMP and ssh connection works fine

I have quite odd problem which i had for quite a time. I'm using powerful OVH dedicated server and i'm not sure what exactly is a root issue here. I've migrated out of Cloudflare cdn, so this problem ...
0
votes
1answer
65 views

Multiple Projects under single Domain Nginx

I have two projects with the different path locations that need to be configured under a single domain with separate upstream PHP 7.1 and HHVM. I am trying to achieve the goal with nginx alias ...
1
vote
0answers
124 views

How to escape/quote a dollar sign `$` in an env var in a php-fpm pool?

As symfony4 uses dotenv and environment variables for configuration, they are also needed on the server. to pass the variables it is possible to add the following to the pool config: example-pool....
0
votes
0answers
40 views

tell apache virtual hosts to connect to php-fpm sockets using different user/group each

I've been reading the php-fpm documentation and found out that I can give each socket its own user, group and mode, but how can I tell apache (per vhost I mean) to use x user and y group to connect to ...
0
votes
0answers
236 views

cannot access laravel site hosted on centos with nginx

I installed nginx + php7.0 + laravel on a remote server with os centos7. I placed my laravel project inside /usr/share/nginx/html/my-laravel/ and I modified /etc/php-fpm.d/www.conf as below: user = ...
0
votes
1answer
48 views

Nginx / PHP-FPM hanging connections

I noticed that my server this morning was not responding. received nginx error page after waiting some time for the page to load. I decided to restart php-fpm because I figured there was an issue ...
0
votes
0answers
41 views

Php-fpm from php.earh repos over Alpine Linux VM: Unable to create the PID file

I have installed php-fpm7.2 from php.earth repositories by following the instructions and running the command: sudo apk add php7 php7-fpm Then when I launch the php-fpm directly as: sudo php-fpm I ...
1
vote
1answer
31 views

NGINX: Primary script unknown - when calling a dynamic URL with controller prefix

We facing a problem and we can't fix it. We are currently able to run our application as expected - SEO URL runs like a charm and are rewriting to index.php. The problem is, we have an additional URL ...
0
votes
1answer
604 views

PHP-FPM Cannot Get UID For User

I have setup an AWS EC2 linux instance and installed the following: httpd24 php71 php71-fpm php71-mysqlnd mod24_ssl fcgi mod24_fcgid I am wanting to run apache 2.4, php 7.1 and php-fpm. In the below ...
0
votes
0answers
18 views

How can I determine a reasonable value for pm.max_children in dynamic mode?

I really don't understand the purpose of this variable - what exactly is the purpose of it? To prevent the exhaustion of ram? It seems ineffective as each request could use a variable amount of ram up ...