Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #270893
| From | Michael Kjörling <c9bc136c6063@ewoof.net> |
|---|---|
| Newsgroups | linux.debian.user |
| Subject | Re: Debian12 with nginx and php-fpm |
| Date | 2024-07-06 16:50 +0200 |
| Message-ID | <IXeTD-fg3-7@gated-at.bofh.it> (permalink) |
| References | <IXe7f-eJ8-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 6 Jul 2024 13:58 +0000, from stethewwolf@posteo.net (Stefano Prina): > [container]$ tail -n 2 /var/log/nginx/error.log > 2024/07/06 13:19:45 [error] 7365#7365: *1 FastCGI sent in stderr: "PHP > message: PHP Warning: PHP Request Startup: Failed to open stream: > Permission denied in Unknown on line 0; Unable to open primary script: > /var/www/html/info.php (Permission denied)" while reading resp > onse header from upstream, client: 127.0.0.1, server: _, request: "GET > /info.php HTTP/1.1", upstream: > "fastcgi://unix:/var/run/php/php8.2-fpm.sock:", host: "localhost:8090" > 2024/07/06 13:19:45 [error] 7365#7365: *1 FastCGI sent in stderr: "PHP > message: PHP Warning: PHP Request Startup: Failed to open stream: > Permission denied in Unknown on line 0; Unable to open primary script: > /var/www/html/info.php (Permission denied)" while reading resp > onse header from upstream, client: 127.0.0.1, server: _, request: "GET > /info.php HTTP/1.1", upstream: > "fastcgi://unix:/var/run/php/php8.2-fpm.sock:", host: "localhost:8090" > > It is strange because I the file /var/www/html/info.php exists and have to > much open permission 0:) I am unable to replicate your results against a VM running a fairly bare-bones Debian 12 installation. I did however have to do an extra `systemctl restart nginx.service` within the VM guest for the nginx web server to recognize info.php as a PHP script that should be executed, instead of a plain file that should be returned as-is to the client; simply the old-style /etc/init.d "start" that you show in your post did not suffice. I do note that you seem to have a mix of TCP ports here; both 80, 8080 (in the requested URL) and 8090 (in the podman invocation). I would therefore suggest to double-check your podman invocation to make sure it is correct for the intended results, and then double-check that you are requesting the correct URL (primarily host and port) given the conditions from where you are requesting it. For example, you could make a change to the default page and check that this change is reflected in the web browser. -- Michael Kjörling 🔗 https://michael.kjorling.se “Remember when, on the Internet, nobody cared that you were a dog?”
Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Debian12 with nginx and php-fpm Stefano Prina <stethewwolf@posteo.net> - 2024-07-06 16:00 +0200
Re: Debian12 with nginx and php-fpm Michael Kjörling <c9bc136c6063@ewoof.net> - 2024-07-06 16:50 +0200
Re: Debian12 with nginx and php-fpm Stefano Prina <stethewwolf@posteo.net> - 2024-07-11 12:50 +0200
csiph-web