nginx +php-fpm 做代理 报错解决

[error] 23388#23388: *1 FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream, client: 127.0.0.1, server: test.com, request: "GET /index.php HTTP/1.1", upstream: "fastcgi://192.168.9.40:9000", host: "127.0.0.1:8080"

问题原因:之前24行 手动把允许写成any 了,查看php-fpm 的进程也是允许所有,但是好像真的不生效;注释掉,重启php-fpm,访问正常;
nginx +php-fpm 做代理 报错解决

 

2021/12/23 01:34:27 [error] 23388#23388: *1 FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream, client: 127.0.0.1, server: test.com, request: "GET /index.php HTTP/1.1", upstream: "fastcgi://192.168.9.40:9000", host: "127.0.0.1:8080"

该问题是在定义 源节点时,未指定根路径造成的:指定后访问正常 

nginx +php-fpm 做代理 报错解决

 

上一篇:安装PHP环境


下一篇:安装php环境