fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; 改成红色部分变量 root   /usr/local/nginx/html; 把root节点提前到location上面…
配置nginx时一直报错:file not found 错误日志: [error] 12691#0: *6 FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream, client: 192.168.168.1, server: localhost, request: "GET / HTTP/1.1", upstream: "fa…
在centos上成功编译安装nginx 1.4.php 5.4并成功启动nginx和php-fpm后,访问php提示"File not found.",同时在错误日志中看到: 复制代码 代码如下: 2013/10/22 20:05:49 [error] 12691#0: *6 FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream, cl…
报错信息(nginx日志): // :: [crit] #: * stat() : Permission denied), client: 172.21.205.25, server: localhost, request: "GET /user/getUserInfo HTTP/1.1", host: "10.96.83.130:8005" // :: [crit] #: * stat() : Permission denied), client: 172.21.…
一.问题现象 1.安装nginx.php.php-fpm后,浏览器访问php报错,“File not found”: 二.问题排查 1.检查nginx.php-fpm服务是否正常启动,均正常启动: 2.检查服务端口号,分别是nginx:81.php:9000 3.查看nginx错误日志 /usr/local/nginx/logs/error.log   tail -n 20 error.log [error] 24324#0: *31 FastCGI sent in stderr: "Prima…
当安装完最新版的nginx和最新版的PHP以后,使用niginx默认配置文件中的PHP配置会有错误访问指定目录下的php文件时,显示File not found.错误.查看nginx的错误日志显示 90#90: *1 FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream, client: 127.0.0.1, server: 127.0.0.1, requ…
今天重启了mac,突然发现本地的 lnmp 服务不能用了,什么请求都返回了: FastCGI sent in stderr: "Primary script unknown" 这个就很尴尬了,可是我啥也没动啊,但是没有办法,出问题了就得查,google了一下,出这个问题一般有两个原因: 一是nginx的配置文件问题 /usr/local/etc/nginx/nginx.conf (个人的,你们的路径不一定是这个)中的 fastcgi_param 参数配置问题,nginx默认配置为: f…
2013/10/22 20:05:49 [error] 12691#0: *6 FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream, client: 192.168.168.1, server: localhost, request: "GET / HTTP/1.1", upstream: "fastcgi://127.0.…
相信很多配置php环境的都遇到过这个恼人的问题: 浏览器访问php文件,返回来 File not found 查看/var/log/nginx/error.log ,有 “Primary script unknown”,类似如下: // :: [error] #: * FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream, client: 1.2.3.4,…
在对nginx添加fastCGI的支持后,然后进行php页面验证,发现页面识别不到,不清楚什么情况,随后google了下,原来是Nginx内置变量问题惹的祸. 1.平台介绍: 1 2 3 4 5 6 OS Version:        CentOS release 6.4 (Final) Nginx Version:     nginx version: nginx/1.4.3 PHP Version:       PHP 5.5.5 (fpm-fcgi) Mysql Version:    …