: This article mainly introduces the error (failedtoloadresource: net: ERR_CONNECTION_RESET) when uploading large files through Nginx Reverse proxy. if you are interested in the PHP Tutorial, refer to it. Error reported when Nginx Reverse proxy uploads large files (failed to load resource: net: ERR_CONNECTION_RESET)
Http://nginx.org/en/docs/http/ngx_http_core_module.html#client_max_body_size
Body
When using Nginx Reverse proxy to upload large files, an error is reported.
failed toload resource : net :: ERR_CONNECTION_RESET
It is found that the Nginx configuration is incorrect.
Use
client_max_body_size size;
Used to configure the maximum allowed value of the Body in the request. The unit of size is M, and the default setting of Nginx is 1 m. Set the value as needed. For example, the limit is 1 GB:
client_max_body_size 1024m;
This configuration can be placed at any location of http, server, or location, corresponding to different scopes.
Appendix
Official documentation:
Syntax: client_max_body_size size;Default: client_max_body_size 1m;Context: http, server, location
Sets the maximum allowed size of the client request body, specified in the "Content-Length" request header field. if the size in a request exceeds the configured value, the 413 (Request Entity Too Large) error is returned to the client. please be aware that browsers cannot correctly display this error. setting size to 0 disables checking of client request body size.
'). AddClass ('pre-numbering '). hide (); $ (this ). addClass ('Has-numbering '). parent (). append ($ numbering); for (I = 1; I <= lines; I ++) {$ numbering. append ($ ('
'). Text (I) ;}; $ numbering. fadeIn (1700) ;}) ;}; script
The above introduces the error (failed to load resource: net: ERR_CONNECTION_RESET) reported by Nginx Reverse proxy for uploading large files, including some content, and hopes to help friends who are interested in PHP tutorials.