nginx/146 configured virtual host access prompt 'File not found' c9 mainland not found file 404 not found 404 not found repair

WBOY
Release: 2016-07-29 08:54:27
Original
1688 people have browsed it

Check the log tail /var/log/nginx/error.log, it prompts "primary script unknown while reading response header from upstream"

View the configuration file part of the virtual host as follows:

location ~ .php {
  #fastcgi_pass remote_php_ip:9000;
  fastcgi_pass unix:/var/run/php5-fpm.sock;
  fastcgi_index index.php;
  include fastcgi_params;
  set $real_script_name $fastcgi_script_name;
  if  ($fastcgi_script_name ~ "^ (.+?.php)(/.+)$") {
                                                                             set $real_script_name $1; real_script_name;
fastcgi_param PATH_INFO $path_info; }



There is a default configuration file default part in the default file after copying nginx. .+) $; # # #Note: You should have "cgi.fix_pathinfo = 0; H php5 -fpm:                      fastcgi_pass unix:/var/run/php5-fpm.sock;                                                  }

Reload nginx servcie nginx reload the problem is solved,

Can anyone explain why this is?

The above introduces the virtual host access prompt "File not found" configured by nginx/146, including the content of file not found. I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template