Article

  • 9 years

    2 years

    YetiShare / Core

    11461

Enable Large Uploads On Your YetiShare Install

This page details all the settings to consider in order to allow for larger file uploads. It assumes you have at least a VPS server with root access.

Note: If you are running any external file server, these will also need to have these settings.

Yetishare Script

- By default YetiShare uses 'chunking' which means large uploads are sent in chunks of 100MB. This fixes most issues within PHP however some web servers still have limits which can block the upload.
- The settings for YetiShare itself are within the admin area, site settings for each user type.

Server Operating System

- Should be Linux 64bit OS. (32bit has a maximum supported filesize of 2GB)
- Check your /tmp/ folder to ensure this has at least 20GB in available space. This is used when files are uploaded so it can easily get full if it's any lower.

PHP

- Amend the following values in your global php.ini file: (if you have a 32bit OS, these should be set to 2G)
upload_max_filesize = 6G
post_max_size = 6G
Restart your webserver to apply the changes.

Nginx

-  Set the client_max_body_size directive in nginx.conf ( http://www.cyberciti.biz/faq/linux-unix-bsd-nginx-413-request-entity-too-large/)

Apache

-  Set the "LimitRequestBody" directive in either your httpd.conf file or a local .htaccess file. ( http://httpd.apache.org/docs/2.0/mod/core.html#limitrequestbody)

Apache with mod_fcgid

- Set the "FcgidMaxRequestLen" directive in either your httpd.conf file or a local .htaccess file. ( https://httpd.apache.org/mod_fcgid/mod/mod_fcgid.html#fcgidmaxrequestlen)

CloudFlare

- If using CloudFlare, ensure you have allowed file uploads at 100MB in size (the chunking size).

ModSecurity

-  If using ModSecurity, ensure 'SecRequestBodyLimit' is set high on your rules. This can limit the max upload size in addition to the above.

MD5 Hashing

-  On upload, a md5 file hash is created for each file. Depending on your server, these can take time to create and even cause the entire upload process to fail. To bypass this for large files, there's an option in the admin area, site settings called "File Hashing Max Filesize (GB)". Try setting this to "2" and retest.


If the above settings still don't work, have a look in the /logs/ folder of the script, aswell as your web server logs, to see if there's any clues as to what the issue may be.

Troubleshooting

If you're seeing uploads get to 100% then say "NaN% / xMB", make sure you don't have post_max_size = 0 within your php.ini file. Set this to a larger size such as post_max_size = 25G. Then restart Apache/Nginx.