Solution to 403 problems caused by nginx configuration
1. Problem: 403 appears when curling the local domain name configured by nginx

nginx_error.log The log is as follows:

##2. Questions
1. www The configuration of .requesturi.com is as follows: It is found that the root directory is inconsistent with the forbidden files in the error log. In theory, when accessing www.requesturi.com, you should go to /usr/local/nginx/html1 to find it. Why does it show that it is indeed /usr/local? Access to /nginx/html is prohibited?

3. Solution
It can be roughly inferred that www.requesturi.com may not be configured in nginx.conf . Check nginx.conf and find that www.requesturi.com is not configured, and nginx does not allow access to the file directory by default, so a 403 error will occur.



The above is the detailed content of How to solve the 403 problem caused by nginx configuration. For more information, please follow other related articles on the PHP Chinese website!
nginx restart
Detailed explanation of nginx configuration
Detailed explanation of nginx configuration
What are the differences between tomcat and nginx
What is the email address and how to fill it in?
How to Get Started with Buying Cryptocurrencies
What are the methods to implement operator overloading in Go language?
ps adjust edge shortcut keys