Nginx Error: Sorry, the page you were looking for is currently unavailable. Please try again later.

Source: Internet
Author: User

See the process, Nginx, php-fpm are running, to eliminate the program error, then is the configuration problem.

A possible error is due to the Fastcgi_pass configuration in the configuration is wrong

The error is configured as follows

Server {Listen80;    server_name localhost; #CharSet koi8-r;    #Access_log/var/log/nginx/log/host.access.log main; Location~ \.php$ {root/usr/share/nginx/html; Fastcgi_pass 127.0.0.1:80; Fastcgi_index Index.PHP; Fastcgi_param Script_filename$document _root$fastcgi_script_name; includeFastcgi_params; Index index.PHP; }   location/{root/usr/share/nginx/html;    Index index.html; }       #error_page 404/404.html;    #Redirect Server error pages to the static page/50x.html    #Error_page 502 503 504/50x.html; Location=/50x.HTML {root/usr/share/nginx/html; }       #Proxy The PHP scripts to Apache listening on 127.0.0.1:80    #       #Location ~ \.php$ {    #Proxy_pass http://127.0.0.1;    #}      #Pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000    #       #Location ~ \.php$ {    #root html;    #Fastcgi_pass 127.0.0.1:9000;    #Fastcgi_index index.php;    #Fastcgi_param Script_filename/scripts$fastcgi_script_name;    #include Fastcgi_params;    #}      #deny access to. htaccess files, if Apache ' s document Root    #concurs with Nginx ' s one    #       #Location ~/\.ht {    #deny all;    #}  }

Marked red place, I thought is port, but is not, specifically should be PHP-FPM processing PHP script Port bar, change to

Fastcgi_pass 127.0.0.1:9000


Location/{         root/usr/share/nginx/html;        Index index.html;    }

The first time to make Nginx, encountered a lot of problems, records of

Nginx Error: Sorry, the page you were looking for is currently unavailable. Please try again later.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.