天天看點

Failed to load resource: the server responded with a status of 413 (Request Entity Too Large)

1、錯誤描述

Failed to load resource: the server responded with a status of 413 (Request Entity Too Large)
Failed to load resource: the server responded with a status of 413 (Request Entity Too Large)

2、錯誤原因

      上傳檔案時,利用localhost通路系統,不會出現這個問題;用域名通路這個系統時,出現這個問題,提示是:請求實體太大

由于Nginx反向代理伺服器client_max_body_size預設值為1MB,而上傳檔案大于1MB,是以就出現這個錯誤

3、解決辦法

     打開Nginx反向代理伺服器nginx.conf配置檔案,修改client_max_body_size值

     client_max_body_size   30M

繼續閱讀