# Android App doesn't take max filesize?

**URL:** <https://forum.mattermost.com/t/android-app-doesnt-take-max-filesize/11596>\
**Category:** Troubleshooting\
**Created:** [April 28, 2021, 5:10pm UTC](https://forum.mattermost.com/t/android-app-doesnt-take-max-filesize/11596 "2021-04-28T17:10:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![keeshah](https://avatars.discourse-cdn.com/v4/letter/k/d07c76/32.png) [@keeshah](https://forum.mattermost.com/u/keeshah)\
**Post date:** [April 28, 2021, 5:10pm UTC](https://forum.mattermost.com/t/android-app-doesnt-take-max-filesize/11596/1 "2021-04-28T17:10:24Z")

</div>

Summery: Upload on the mobile app doesn’t work with size\>??MB, upload desktop app works fine, upload smaller files also works fine.

**Steps to reproduce**  
Latest Android App, Server version 5.34.2

**Expected behavior**  
File Upload works fine, same size limit as for desktop app.

**Observed behavior**  
When I upload a File on the android app, my nginx tells me in debug mode:  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 http upstream request: “/api/v4/files?”  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 http upstream send request handler  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 http upstream send request  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 http upstream send request body  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 chain writer buf fl:0 s:755  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 chain writer buf fl:1 s:12496475  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 chain writer in: 00005626DC99D620  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 writev: 2586539 of 12497230  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 writev: -1 of 9910691  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 writev() not ready (11: Resource temporarily unavailable)  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 chain writer out: 00005626DC99D630  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 event timer: 43, old: 34798950, new: 34798950  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 http upstream request: “/api/v4/files?”  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 http upstream process header  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 malloc: 00005626DD5F3A60:524288  
2021/04/28 18:38:57 [debug] 133996#133996: \*80 recv: eof:1, avail:-1

Relevant Settings:  
mattermost:  
“FileSettings”: {  
“EnableFileAttachments”: true,  
“EnableMobileUpload”: true,  
“EnableMobileDownload”: true,  
“MaxFileSize”: 1048576000,  
“DriverName”: “local”,  
“Directory”: “./data/”,  
“EnablePublicLink”: true,  
“ExtractContent”: false,  
“ArchiveRecursion”: false,

nginx:  
access\_log /var/log/nginx/mattermost.access.log combined;  
error\_log /var/log/nginx/mattermost.error.log debug;

location ~ /api/v[0-9]+/(users/)?websocket$ {  
proxy\_set\_header Upgrade $http\_upgrade;  
proxy\_set\_header Connection “upgrade”;  
client\_body\_buffer\_size 1000M;  
client\_max\_body\_size 1000M;  
proxy\_set\_header Host $http\_host;  
proxy\_set\_header X-Real-IP $remote\_addr;  
proxy\_set\_header X-Forwarded-For $proxy\_add\_x\_forwarded\_for;  
proxy\_set\_header X-Forwarded-Proto $scheme;  
proxy\_set\_header X-Frame-Options SAMEORIGIN;  
proxy\_buffers 2048 512k;  
proxy\_buffer\_size 512k;  
client\_body\_timeout 60;  
send\_timeout 300;  
lingering\_timeout 5;  
proxy\_connect\_timeout 90;  
proxy\_send\_timeout 300;  
proxy\_read\_timeout 90s;  
proxy\_pass [http://backend](http://backend);  
}

location / {  
client\_body\_buffer\_size 1000M;  
client\_max\_body\_size 1000M;  
proxy\_set\_header Connection “”;  
proxy\_set\_header Host $http\_host;  
proxy\_set\_header X-Real-IP $remote\_addr;  
proxy\_set\_header X-Forwarded-For $proxy\_add\_x\_forwarded\_for;  
proxy\_set\_header X-Forwarded-Proto $scheme;  
proxy\_set\_header X-Frame-Options SAMEORIGIN;  
proxy\_buffers 2048 512k;  
proxy\_buffer\_size 512k;  
proxy\_read\_timeout 600s;  
proxy\_cache mattermost\_cache;  
proxy\_cache\_revalidate on;  
proxy\_cache\_min\_uses 1;  
proxy\_cache\_use\_stale timeout;  
proxy\_cache\_lock on;  
proxy\_http\_version 1.1;  
proxy\_pass [http://backend](http://backend);  
}  
}
