The server always reports 502 errors. How to solve this problem?

1. Server 500 error
The server 500 error is an internal error of the server,
possible reason
1. Programming language error, such as ASP or PHP syntax error;
2. Due to high concurrency, too many files cannot be opened due to system resource limitations;
2. Server 501 error
The server does not support the requested function and cannot complete the request. This code may be returned when the server cannot recognize the requested method.
3. Server 502 error
The 502 error is a failure of the WEB server, which may be due to insufficient program processes. The requested php-fpm has been executed, but for some reason the execution has not been completed, resulting in the termination of the php-fpm process.
possible reason:
1. Nginx server, the number of php-cgi processes is not enough;
2. PHP execution time is too long;
3. The php-cgi process died;
4. Server 503 error
The server is currently unavailable, and the system maintenance server is temporarily unable to process client requests. This is only a temporary state. You can contact the server provider.
5. Server 504 error
The server 504 error indicates a timeout, which means that the request sent by the client did not reach the gateway, and the request did not reach the executable php-fpm, which is generally related to the configuration of nginx.conf.
6. Server 505 error
The server does not support the HTTP protocol version used in the request. Generally, the browser defaults to the 1.x version under the payment. If the HTTP1.1 version appears, then you need to set it under the advanced Internet options .
Except for the 500 error, which may be a programming language error, all other errors can probably be understood as a problem with the server

1. Server 500 error

The server 500 error is an internal error of the server,
possible reason
1. Programming language error, such as ASP or PHP syntax error;
2. Due to high concurrency, too many files cannot be opened due to system resource limitations;
2. Server 501 error
The server does not support the requested function and cannot complete the request. This code may be returned when the server cannot recognize the requested method.
3. Server 502 error

The 502 error is a failure of the WEB server, which may be due to insufficient program processes. The requested php-fpm has been executed, but for some reason the execution has not been completed, resulting in the termination of the php-fpm process.
possible reason:
1. Nginx server, the number of php-cgi processes is not enough;
2. PHP execution time is too long;
3. The php-cgi process died;
4. Server 503 error

The server is currently unavailable, and the system maintenance server is temporarily unable to process client requests. This is only a temporary state. You can contact the server provider.
5. Server 504 error

The server 504 error indicates a timeout, which means that the request sent by the client did not reach the gateway, and the request did not reach the executable php-fpm, which is generally related to the configuration of nginx.conf.
6. Server 505 error
The server does not support the HTTP protocol version used in the request. Generally, the browser defaults to the 1.x version under the payment. If the HTTP1.1 version appears, then you need to set it under the advanced Internet options .
Except for the 500 error, which may be a programming language error, all other errors can probably be understood as a problem with the server