# Upload Artifact fails because of size

**URL:** <https://hub.mender.io/t/upload-artifact-fails-because-of-size/2887>\
**Category:** General Discussions\
**Created:** [November 24, 2020, 11:53am UTC](https://hub.mender.io/t/upload-artifact-fails-because-of-size/2887 "2020-11-24T11:53:59Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![trailsurfer](https://avatars.discourse-cdn.com/v4/letter/t/87869e/32.png) [@trailsurfer](https://hub.mender.io/u/trailsurfer)\
**Post date:** [November 24, 2020, 11:53am UTC](https://hub.mender.io/t/upload-artifact-fails-because-of-size/2887/1 "2020-11-24T11:53:59Z")

</div>

Hello, I am currently testing mender with a self hosted mender Server in demo mode, Version: 2.5.0  
I was using raspberry Pi as client, and everything worked very well. Then I tried with x86 debian machine as client. I did a system snapshot and created a artifact from the snapshot.

> **[Create an Artifact with system snapshot | Mender documentation](https://docs.mender.io/2.5/artifact-creation/create-an-artifact-with-system-snapshot)**

  
Then I tried to upload the Artifact, (14.32 GB) what wasn’t possible. The upload started, the upload in progress increases up to 20% (Upload in progress (20%)) and then jumping back to 0%, also the graphical green process bar is jumping back, all this repeating several times. I guess its a space problem on my server, but I can’t figure out how to give the upload the additional space it needs for buffering the bigger Artifact. Upload of “small” artifacts works fine that have 3 GB.  
Docker logs say: 2020/11/24 09:45:52 [error] 30#30: \*246 client intended to send too large body: 15370870261 bytes, client: xx.xx.xx.xx, server: [mender.intern.xxxx.net](http://mender.intern.xxxx.net), request: “POST /api/management/v1/deployments/artifacts HTTP/1.1”, host: “x.x.x.x”, referrer: “[https://x.x.x.x/ui/](https://x.x.x.x/ui/)”

Does anybody has a Idea how to enable larger artifact sizes ?

Thanks for your effort to read and your help ! Best regards, Alexander

---

<div class="post-metadata">

**Author:** ![tranchitella](https://yyz2.discourse-cdn.com/flex036/user_avatar/hub.mender.io/tranchitella/32/606_2.png) [@tranchitella](https://hub.mender.io/u/tranchitella)\
**Post date:** [November 24, 2020, 12:14pm UTC](https://hub.mender.io/t/upload-artifact-fails-because-of-size/2887/2 "2020-11-24T12:14:07Z")

</div>

Hello @trailsurfer, the maximum payload size when uploading artifacts is 10GB:

> <https://github.com/mendersoftware/mender-api-gateway-docker/blob/2.3.x/common.nginx.conf#L138>

If yo have a 14GB artifact, I believe the only option you have is rebuilding the Docker image for the api gateway increasing the client\_max\_body\_size.

---

<div class="post-metadata">

**Author:** ![alfrunes](https://yyz2.discourse-cdn.com/flex036/user_avatar/hub.mender.io/alfrunes/32/703_2.png) [@alfrunes](https://hub.mender.io/u/alfrunes)\
**Post date:** [November 24, 2020, 12:52pm UTC](https://hub.mender.io/t/upload-artifact-fails-because-of-size/2887/3 "2020-11-24T12:52:51Z")

</div>

I’m afraid there is a [hard limit](https://github.com/mendersoftware/deployments/blob/2.1.x/app/app.go#L55) on the upload size set to 10GiB in the backend service managing deployments and artifact storage.  
One option you can do is to try a better compression algorithm when creating the artifact:

```auto
mender-artifact write rootfs-image -f ssh://${USER}@${ADDR} \
                                   -n artifact-name \
                                   -o snapshot-release.1.0.mender \
                                   -t device-type \
                                   --compression lzma

```

NOTE: lzma compression requires liblzma to be installed on the devices receiving this update.

I have created a [ticket](https://tracker.mender.io/browse/MEN-4184) to track this issue and make the artifact limit configurable.

---

<div class="post-metadata">

**Author:** ![mho](https://avatars.discourse-cdn.com/v4/letter/m/a183cd/32.png) [@mho](https://hub.mender.io/u/mho)\
**Post date:** [October 5, 2021, 10:29pm UTC](https://hub.mender.io/t/upload-artifact-fails-because-of-size/2887/4 "2021-10-05T22:29:18Z")

</div>

> [@alfrunes](#):
>
> ticket

Is there any update on this? We have much larger artifacts, and it’s making it difficult for us to use Mender - we need to recompile it from source.

---

<div class="post-metadata">

**Author:** ![dellgreen](https://yyz2.discourse-cdn.com/flex036/user_avatar/hub.mender.io/dellgreen/32/85_2.png) [@dellgreen](https://hub.mender.io/u/dellgreen)\
**Post date:** [October 5, 2021, 11:09pm UTC](https://hub.mender.io/t/upload-artifact-fails-because-of-size/2887/5 "2021-10-05T23:09:59Z")

</div>

Have you gone through your Golden Image to remove anything you don’t need, as there is normally an awful lot that can be removed to reduce the size of it without affecting functionality. Often there is a lot of caching of packages by the package manger as well as multiple kernels/modules, man page removal, swap file etc that take up a lot of unnecessary space. A 14GB compressed mender artifact does seems a little on the large size. Once you start auditing your root file system, you will often be surprised as to what’s consuming space that you were unaware of.

There’s a more in-depth discussion below on large image sizes.

> [@\[FATAL\] \[mender-convert-package\] You can try adjusting the MENDER\_STORAGE\_TOTAL\_SIZE\_MB variable to increase available space, or](https://hub.mender.io/t/fatal-mender-convert-package-you-can-try-adjusting-the-mender-storage-total-size-mb-variable-to-increase-available-space-or/3744/7):
>
> You will need to adjust the variables I mentioned above to make sure it all fits. You may also need to set IMAGE\_ROOTFS\_SIZE to “-1”. Drew

---

<div class="post-metadata">

**Author:** ![mho](https://avatars.discourse-cdn.com/v4/letter/m/a183cd/32.png) [@mho](https://hub.mender.io/u/mho)\
**Post date:** [October 5, 2021, 11:23pm UTC](https://hub.mender.io/t/upload-artifact-fails-because-of-size/2887/6 "2021-10-05T23:23:29Z")

</div>

Our fully-stripped binaries alone are ~20GB, without the OS image.  
Oh, and to be clear, I’m not the OP, I think my artifacts are going to be much much larger than 14GB - I was just wondering if any progress was made on this, because I’m in the same boat.

---

<div class="post-metadata">

**Author:** ![alfrunes](https://yyz2.discourse-cdn.com/flex036/user_avatar/hub.mender.io/alfrunes/32/703_2.png) [@alfrunes](https://hub.mender.io/u/alfrunes)\
**Post date:** [October 6, 2021, 1:47pm UTC](https://hub.mender.io/t/upload-artifact-fails-because-of-size/2887/7 "2021-10-06T13:47:53Z")

</div>

Unfortunately this ticket has not been prioritized.

Just out of curiosity, if I may ask, what kind of application are you running on your images?

---

<div class="post-metadata">

**Author:** ![aakash\_goyal](https://avatars.discourse-cdn.com/v4/letter/a/edb3f5/32.png) [@aakash\_goyal](https://hub.mender.io/u/aakash_goyal)\
**Post date:** [February 14, 2025, 9:27am UTC](https://hub.mender.io/t/upload-artifact-fails-because-of-size/2887/9 "2025-02-14T09:27:36Z")

</div>

Is there any update on this? Because I tried to upload an artifact of more than 10 GB and it failed because of size.

---

<div class="post-metadata">

**Author:** ![TheYoctoJester](https://yyz2.discourse-cdn.com/flex036/user_avatar/hub.mender.io/theyoctojester/32/1444_2.png) [@TheYoctoJester](https://hub.mender.io/u/TheYoctoJester)\
**Post date:** [February 14, 2025, 9:52am UTC](https://hub.mender.io/t/upload-artifact-fails-because-of-size/2887/10 "2025-02-14T09:52:33Z")

</div>

Hi @aakash_goyal,

No update here and also none expected, as the defined maximum artifact size on Hosted Mender is 10GB. If your requirements go beyond that, please get in touch with our [sales team](mailto:contact@mender.io) to figure out a solution.

Greetz,  
Josef
