(EDITED)
What I’m trying to do:
Upload a file (orginally 1.36 GB) to the assets in Umbraco. Currently having problems in:
- dev-Env even with small files - see “integer Overflow error”
- live-Env with large files - see “large files”
integer Overflow error (dev)
When trying to upload seemingly any file to the assets I get an error in the backoffice along the lines of:
The error shown below resulted from trying to upload a 17 kB webp file
Error: System.IO.InvalidDataException: Multipart body length limit -699400192 exceeded.
The interessting thing here is that I configured all configs to allow 2GB
appsettings.json
"Runtime": {
"MaxQueryStringLength": 90,
"MaxRequestLength": 2000000000
},
web.config
<requestFiltering>
<requestLimits maxAllowedContentLength="2000000000" />
</requestFiltering>
Program.cs
builder.Services.Configure<FormOptions>(options =>
{
options.MultipartBodyLengthLimit = 2000000000;
});
Large files fail to upload
When trying to upload a large file (1.36 GB) the upload stays at 100% and the debug conole of the brower shows the following. On the other hand files of a size like 300 or 825 MB have no problem in beeing uploaded.
Possibly unhandled rejection:
{
"data": null,
"status": -1,
"config": {
"method": "POST",
"transformRequest": [
null
],
"transformResponse": [
null
],
"jsonpCallbackParam": "callback",
"url": "/umbraco/backoffice/umbracoapi/media/PostAddFile",
"fields": {
"currentFolder": "1324",
"contentTypeAlias": "umbracoAutoSelect",
"propertyAlias": "umbracoFile"
},
"file": {
"key": "8cd4722b-0127-4cae-a5a3-e5da31386fbe",
"messages": []
},
"_isDigested": true,
"_chunkSize": null,
"headers": {
"Accept": "application/json, text/plain, */*",
"X-Requested-With": "XMLHttpRequest",
"X-UMB-SEGMENT": null,
"X-UMB-XSRF-TOKEN": "CfDJ8NmAoZtxGFBMmfT2L703U5tz5MfwPyG7y3DOdSdQGyQa-ZxkJ2UQLhhuSQoRHY154oG6cLiKc078eEeFr6LoLBzOXjsTy4RkHVMRT3HTR6bRFZ5zRPTMAPFKq7eK7o-Ajr5nRvD7iSES-YLNYswPvEza3VFno3OUI15M6Ev7cKUFvk1DuOGJlfqC2SPg7Dferg"
},
"_deferred": {
"promise": {}
}
},
"statusText": "",
"xhrStatus": "error"
}
Furthermore, the post request get rejected with “NS_ERROR_CONNETION_REFUSED” after the upload “has finished” . I thought the problem might be the file size limitations but I adjusted both in the appsettings.json and the web.config just to be sure.
What am I running:
Dev:
- JetBrains Rider with IIS-Express Run Config
- Umbraco v13.7.0 (updated as recommend by LuukPeters
Live
- Umbraco v13.6.0
- inside a docker container
- hidden behind a traefik proxy
I appriciate any help, thanks!