couple of days ago, I came across an issue where when user leave the web page idle and try to upload a file using JQuery-FileUpload; user was getting error 413. and sometimes users were getting “The page was not displayed because the request entity is too large.” error.
I increased the uploadReadAheadSize value on IIS and that was enough to fix the issue; I did the followings:
- Launch “Internet Information Services (IIS) Manager”
- Select the site that you are hosting your web application under it.
- In the Features section, double click “Configuration Editor”
- Under “Section” select: system.webServer then serverRuntime
- Modify the “uploadReadAheadSize” section to be like 20MB (the value there is in Bytes)
- Click Apply
The error is happening as during renegotiation step between your web browser and the IIS Server; the entity should be preloaded using SSL. and result is being larger than the default value which is ~49K