# Plugin Upload failed

**URL:** <https://forum.mattermost.com/t/plugin-upload-failed/16668>\
**Category:** Troubleshooting\
**Created:** [August 16, 2023, 3:46pm UTC](https://forum.mattermost.com/t/plugin-upload-failed/16668 "2023-08-16T15:46:08Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![kushalm](https://avatars.discourse-cdn.com/v4/letter/k/9fc348/32.png) [@kushalm](https://forum.mattermost.com/u/kushalm)\
**Post date:** [August 16, 2023, 3:46pm UTC](https://forum.mattermost.com/t/plugin-upload-failed/16668/1 "2023-08-16T15:46:09Z")

</div>

For feature requests, please see: [https://mattermost.com/suggestions/](https://mattermost.com/suggestions/).

For troubleshooting questions, please post in the following format:

**Summary**  
When I am trying to upload a plugin in the tar.gz format, I get an error. Tried doing it using webconsole and mmctl. I am running mattermost in a docker container with Nginx.

**Steps to reproduce**  
Installing Mattermost server using docker. Follow the link here:[Install Mattermost via Docker — Mattermost documentation](https://docs.mattermost.com/install/install-docker.html)

Server version 8.0.1

Web console

Download a plugin, for example [Releases · mattermost/mattermost-plugin-ai · GitHub](https://github.com/mattermost/mattermost-plugin-ai/releases). Go to system console \> plugin management\> and upload plugin. Select the plugin the upload it. You should see the error at this point.

mmclt  
Download and authenticate with the mattermost server. upload the plugin using  
./mmctl plugin add

**Observed behavior**  
Whenever I try to upload any plugins in the tar.gz format from the web console. I get " Received invalid response from the server.". Similarly, when I try to use mmctl to upload any plugin, I get the following error:  
Error: AppErrorFromJSON: model.utils.decode\_json.app\_error, body:

413 Request Entity Too Large
# 413 Request Entity Too Large

* * *
nginx/1.25.1 , invalid character '\<' looking for beginning of value.

---

<div class="post-metadata">

**Author:** ![john.combs](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mattermost.com/john.combs/32/7118_2.png) [@john.combs](https://forum.mattermost.com/u/john.combs)\
**Post date:** [August 16, 2023, 10:20pm UTC](https://forum.mattermost.com/t/plugin-upload-failed/16668/2 "2023-08-16T22:20:52Z")

</div>

Hi Kushal,

Welcome to the Mattermost Community Forums!

It seems that you’re encountering an error when trying to upload a plugin in the tar.gz format to your Mattermost server running in a Docker container with Nginx. The error you receive from both the web console and mmctl indicates an issue with the size of the request.

To address this, you can try adjusting the configuration related to maximum request size in both Nginx and Mattermost.

For Nginx:

1. Locate the Nginx configuration file for your Mattermost server.
2. Look for the `client_max_body_size` directive.
3. Increase the value of `client_max_body_size` to a higher limit, such as `100M` for 100 megabytes.
4. Save the configuration file and restart Nginx.

For Mattermost:

1. Access your Mattermost server’s Docker container.
2. Locate the Mattermost configuration file, which is typically named `config.json`.
3. Open the `config.json` file and add or modify the `"MaximumFileSize"` setting to increase the maximum allowed file size. For example:

```auto
"FileSettings": {
    ...
    "MaximumFileSize": 104857600, // 100 megabytes in bytes
    ...
},

```

1. Save the `config.json` file and restart the Mattermost server container.

After applying these changes, try uploading the plugin again using both the web console and mmctl. The increased limits should allow the upload to proceed without encountering the “Request Entity Too Large” error.

Let me know if you have any further questions or encounter any issues during this process!

Best regards,  
~Matterbot 2.0 🤖

_[ **Disclaimer:** This is a new AI response feature we’re testing powered by ChatGPT. Please note that this suggestion may not always reflect official Mattermost recommendations or support.  
Were any of the above suggestions inaccurate? **Let us know by replying to this comment!** ]_

---

<div class="post-metadata">

**Author:** ![mangesh\_x0](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mattermost.com/mangesh_x0/32/7770_2.png) [@mangesh\_x0](https://forum.mattermost.com/u/mangesh_x0)\
**Post date:** [April 6, 2024, 6:08pm UTC](https://forum.mattermost.com/t/plugin-upload-failed/16668/3 "2024-04-06T18:08:16Z")

</div>

Hi John,

after following all the above steps, I was still not able to get rid of that error. even after increasing the size to 500mb I still get the same error " Received invalid response from the server."

---

<div class="post-metadata">

**Author:** ![john.oliver](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mattermost.com/john.oliver/32/6436_2.png) [@john.oliver](https://forum.mattermost.com/u/john.oliver)\
**Post date:** [April 8, 2024, 6:02pm UTC](https://forum.mattermost.com/t/plugin-upload-failed/16668/4 "2024-04-08T18:02:21Z")

</div>

> [@kushalm](#):
>
> nginx/1.25.1 , invalid character ‘\<’ looking for beginning of value

Look in your nginx config for an extra ‘\<’ I’m guessing that’s stopping it from reading the size value.
