OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



File size upload maximum

Are you responsible for making OMP work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, michael, asmecher

Forum rules
What to do if you have a technical problem with OMP:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OMP Discussion subforum; if you have a development question, try the OMP Development subforum.

File size upload maximum

Postby vlilloh » Wed Apr 17, 2013 5:19 am

Hi,

Both OMP 1.0b and OMP 1.0.0, in "Upload a Proof", I can't upload a file with more than 20M, only less than 20M, despite OMP tell me that the file size upload maximum is 40M and upload_max_filesize is set in 50M.

Thanks.
Attachments
captura2.png
captura2.png (5.77 KiB) Viewed 2437 times
captura1.png
captura1.png (46.25 KiB) Viewed 2437 times
vlilloh
 
Posts: 285
Joined: Thu Feb 07, 2008 3:35 am
Location: Murcia, Spain

Re: File size upload maximum

Postby asmecher » Wed Apr 17, 2013 10:23 am

Hi Vicente,

I'm not sure what's causing the 40M/50M discrepancy -- OMP gets the file size maximum from PHP using:
Code: Select all
get_cfg_var('upload_max_filesize')
(See e.g. lib/pkp/controllers/wizard/fileUpload/form/PKPSubmissionFilesUploadForm.inc.php.)

There might be additional limits on the maximum POST size, both in PHP and Apache's configuration. For PHP, see the post_max_size directive; for Apache, see the LimitRequestBody directive.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8676
Joined: Wed Aug 10, 2005 12:56 pm

Re: File size upload maximum

Postby vlilloh » Wed Apr 17, 2013 1:21 pm

Hi Alec,

post_max_size = 50M, as well.

LimitRequestBody I don't know, tomorrow I'll ask to the Administrator.

Thanks.
vlilloh
 
Posts: 285
Joined: Thu Feb 07, 2008 3:35 am
Location: Murcia, Spain

Re: File size upload maximum

Postby vlilloh » Fri Apr 19, 2013 5:10 am

Hi Alec,

The Administrator told me that LimitRequestBody is not set in Apache, so there is no limit here. And as I told you, upload_max_filesize = 50M and post_max_size = 50M.

We have tried with the Upload-File Form & Script of http://www.w3schools.com/php/php_file_upload.asp. And the test works correctly. It only allows files up to 50M.

The Administrator insists that there is not error in the hosting.

Thanks.
vlilloh
 
Posts: 285
Joined: Thu Feb 07, 2008 3:35 am
Location: Murcia, Spain

Re: File size upload maximum

Postby asmecher » Fri Apr 19, 2013 1:41 pm

Hi Vicente,

Is it possible that you're hitting a request timeout rather than a size limit? When you're uploading a large file, try timing it to see how long it takes to fail. If it's failing at a round number (typically 5 minutes) then there are a few time-related PHP configuration directives that might be at play.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8676
Joined: Wed Aug 10, 2005 12:56 pm

Re: File size upload maximum

Postby vlilloh » Mon Apr 22, 2013 1:14 am

Hi Alec,

There is no waiting. The system does absolutely nothing. It is as if the system does not recognize the PDF with more than 20M. I'm trying both by "Add files" and Drag&Drop.

Thanks.
vlilloh
 
Posts: 285
Joined: Thu Feb 07, 2008 3:35 am
Location: Murcia, Spain

Re: File size upload maximum

Postby asmecher » Mon Apr 22, 2013 10:21 am

Hi Vicente,

I found it -- there's a hard-coded limit in lib/pkp/js/controllers/UploaderHandler.js:
Code: Select all
max_file_size: '20mb',
I've filed this as a bug in http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8203, but meanwhile, feel free to modify the hard-coded limit in the above file.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8676
Joined: Wed Aug 10, 2005 12:56 pm

Re: File size upload maximum

Postby vlilloh » Tue Apr 23, 2013 1:05 am

Hi Alec,

Yes, all right now :) 50M is now the real limit.

Anyway, notice that the message is the same: "This server allows a file size upload maximum of 40M. If required, please contact ... for assistance." And my hosting is set with upload_max_filesize = 50M and post_max_size = 50M.

Thanks.
vlilloh
 
Posts: 285
Joined: Thu Feb 07, 2008 3:35 am
Location: Murcia, Spain

Re: File size upload maximum

Postby asmecher » Tue Apr 23, 2013 8:02 am

Hi Vicente,

Glad to hear large file uploads are now working. For the last part, that 40M value is still coming from PHP somehow; I'd suggest investigating with a test script that displays the value of get_cfg_var('upload_max_filesize') to see if it returns the same outside of OMP.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8676
Joined: Wed Aug 10, 2005 12:56 pm

Re: File size upload maximum

Postby ojshelpatucalgary » Mon Nov 04, 2013 3:58 pm

We were having this same problem so I followed your advice to modify the hard-coded limit in lib/pkp/js/controllers/UploaderHandler.js
That does work but I thought that, to save others the fiddling, I'd mention that it doesn't work in every browser.
    On the Mac it works in Safari 5.1 but not on Firefox 24 or 25.
    On PC it works on Firefox 25 and Chrome.
It would be nice for users if there were some type of feedback from the program to notify you that your file is too large for upload and to contact your support help.
ojshelpatucalgary
 
Posts: 10
Joined: Fri Feb 08, 2013 4:14 pm
Location: Calgary


Return to OMP Technical Support

Who is online

Users browsing this forum: No registered users and 1 guest

cron