VM & WP - Unable to upload files > 100mb

SYSTEM INFORMATION
OS type and version: Ubuntu Linux Server 16 LTS
Webmin version: 1.981
Virtualmin version: 6.17-3
Related products version: RECOMMENDED

Hi team,
First of all, a promise. I will; NOT abandon this support forum thread. I will actively monitor it and appreciate your contributions.

This has been an issue on my VirtualMin host for a number of months. The site primarily serves downloads, so a helping hand with this game breaker would be nice :slight_smile:

Details (additional):
Old installation of VirtualMin (4years+)
Learning platform carried into live from LIVE
Many changes made that I may not have fully understood.

I’ve been running this install of VirtualMin for a while and I prefer not to nuke it and start again - every issue solved contributes to learning. I learnt all that I know starting with VirtualMin and home VPS hosting.

On my WordPress site, BMSworld.nz, I am unable to upload any .ZIP file greater than 100MB.
60MB = noticeably slower upload considering workstation > server in same room
80MB = slower still, higher chance of failure

100MB, Guaranteed failure to upload.
Note that a failure to upload is defined as - Uploading a .zip to a Wordpress Download Manager. Upload starts but stalls immediately if >100MB
Checked with Plugin Author who remotely went over my system and determined that there’s no issue with their plugin.

Maximum HTTP POST size = 5000MB
Maximum file upload size = 5000MB
/home/bmsworld/etc/php7.0/php.ini < this file defines the above values: CONFIRMED
The above php.ini file is KNOWN but not CONFIRMED to be the directives in play. Wouldn’t be able to imagine any reason why the only php.ini file would be ignored or directives read from somewhere else?

I have already put a fair bit of research into this issue on my webhost at home. Find myself here.

Remote access can be granted and a donation offered if you can fix this. It’s driving me nuts!

@produKtnz,

What “php script execution mode” is configured on Virtualmin > Server Configuration > PHP Options for the given domain?

*** BTW: if you are still running Ubuntu 16.04 LTS, it has reached it’s “end-of-life”. you should upgrade to at least 18.04 LTS ***

1 Like

Noted - I missed the EOL on this one

“* What “php script execution mode” is configured on Virtualmin > Server Configuration > PHP Options for the given domain?*”
FCGid

I have changed the execution mode to CGIwrapper, this allows the file to be uploaded to the php limits specified (now 2000M) however now it stalls at the end of the file.

Smaller files (60MB) upload and finalize fine
Larger files (400MB) upload fine, but freezes at 100%, never completing

wp-content and wpcontent\uploads are (0755/drwxr-xr-x) respectively in File Manager

@produKtnz,

Recommended execution mode is either PHP-FPM (merged with PHP project) or FCGId (an earlier implementation of what essentially FPM offers now).

If using FCGId, navigate to:

Virtualmin > Services > PHP 7.0.33 Configuration

There you can adjust the “Resource Limits” which essentially on a CentOS machine will edit the file at:

/home/username/etc/php7.0.33/php.ini

*** the above path may be reduced to “php7.0” instead of the above ***

Sometimes, while after adjusting these settings Apache is suppose to restart to let them take effect, you may need to restart Apache manually to see the settings take effect.

To confirm the new settings are active for your domain, in the root of your website (public_html folder), create a file called phpinfo.php and add the line:

<?php echo phpinfo();?>

View this page in your browser, and it’ll show you what configurations are active for “that” domain.

As requested: https://www.bmsworld.nz/phpinfo.php
php.ini files loaded specify an increased execution time, memory amount max post size etc as appropriate.
Have not yet investigated whether virtualmin is picking up any files in the /etc/php/7.0/cgi/conf.d directory though.

Also, this might be a nugget.
Ignoring the mixed content to be fixed (FINALLY the last mixed item to fix that is … )

With the screenshot below, we might be leaving the realm of VirtualMin support scope. Feel free to validate this.
NB: DevTools screenshot was taken at the moment the upload froze.

Excuse me for I didn’t read the details carefully of the question and answers,
but I’ve faced an upload limit in two cases and learned it the hard way:

  • nginx has a default small upload limit. If you’re using nginx you should add a setting to increase that with the setting client_max_body_size.
  • Cloudflare imposes a 100 MB upload limit on free plans. If you’re using Cloudflare with your site (and it seems you are), here are my suggestions:
    • Upgrade your Cloudflare plan. If it is not currently free, check out the upload setting and increase it.
    • Use a separate unproxied subdomain for uploads.
    • Use an upload manager tool/script that can chunk up the upload to little requests, and also provide a helpful progress bar to the user.

I’m using the free Cloudflare plan for DNS. I have no such limits. Largest file I’ve uploaded was a Wordpress backup that was 3.9 GB in size.

Don’t take it from me.
Here it is from the “Network” settings.

It could be that you used a chunk uploader, or i just don’t know. Or you’re not using the Cloudflare proxy (as you said you are just using the DNS), in that case there’s no restriction.

That’s for a visitor to your site, not the admin of the site being run. They’re not going to host a file server for free. You’re completely misrepresenting what that setting is.

Example: I can upload a 12 GB video file to my site from my admin panel if I want to with no problem at all. But they’re not going to let 15 visitors to my site do that at the same time because it would be ridiculous amounts of traffic for Cloudflare to give away for free.

You’re confusing what your visitors to your domain can do with what you personally can do on that same domain as an admin of the site. They are two separate things.

I had previously read about Cloudflare’s 100MB caching limit and have turned on Development mode for now.
Now re-testing and will update here.

Cloudflare has never had a 100 MB caching limit.

It’s 500 MB for everybody except the enterprise edition which goes to 5GB. If you’re using more than 500 MB, you’re probably hosting NASA’s website.

did you try changing maximum php script run time to 300 seconds or more?
40" might be too low, depending on upload speed/connection.

and a tip : remove cloudflare if your audience is physically located in just one country/continent. it just makes website slower…

Nothing so far has helped, but this could suggest a few reasons why everything is going so badly.

Domain: bmsworld.nz
Type: unauthorized
Detail: Incorrect TXT record
“-xx5a2lA9EIOMNHZNiawkVsphGBwNOQyYTXeukw6Ei0” found at
_acme-challenge.bmsworld.nz

How does one retrieve what the actual acme-challenge TXT record should be ?

I can tell you that .nz is not supported in the United States. I don’t know if that’s what’s causing you some issues but I do know that in the U.S. you’ll get the dreaded TLD not supported error every single time using that domain name.

Here it is from GoDaddy:

About .nz domains

Domain Name Commission is the sponsor and Key Systems is our backend provider for the country-code top-level domain name (ccTLD) .nz extension that represents New Zealand.

Who can register .nz domains?

Anyone can register a .co.nz, .net.nz, .org.nz domain.

  • .nz - Not supported.
  • .co.nz - Intended for commercial entities.
  • .net.nz - Intended for network infrastructures, such as Internet Service Providers.
  • .org.nz - Intended for non-profit organizations.

why would a TXT record affect upload? maybe you’ve got it all wrong or something missing in your issue report(?) anyway, check your letsencrypt.log for details.

yeah txt have nothing to do with upload same for lets enctrypt… txt is about emails and lets encrypt is about ssl… EH!

on wordpress end it would be php configuration and make sure you have ram… I managed in past to get uploads about 1gigs… I think I have somewhere screenshots… I will post them to you here once I find old hdd…setup is via web - possibly meaning answer to your question… however how about ssh? like upload files via filezilla? no?

@produKtnz as I seen your HAR screenshot - you have to fix your html in your website but this would still have no affect on your upload speed. You just need to fix mixed content within your page.

No. You’re misunderstanding. GoDaddy won’t register an .nz domain. But, they work fine in the US.

1 Like

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.