Please help us to make AbanteCart Ideal Open Source Ecommerce Solution for everyone.

Support AbanteCart eCommerce

Author Topic: SOLVED - Uploading large files to download section - PLEASE  (Read 22209 times)

Offline buddahboy

  • Full Member
  • ***
  • Posts: 234
  • Karma: +32/-0
    • View Profile
SOLVED - Uploading large files to download section - PLEASE
« on: October 28, 2013, 07:33:01 PM »
Greetings,

My php.ini on the server allows for a max of 600mb and the php.ini within AbanteCart's directory is also set for 600mb - I see in AbanteCart under system settings  that I can upload up to 600mb (screenshot attached).  I try to upload a 572mb file and get an error message  600.04 MB  Error: True  -  the file is not 600 mb.   

Any thoughts? 

Thanks,
Ron
« Last Edit: November 15, 2013, 08:57:16 PM by buddahboy »
AbanteCart is one hell of a shopping cart.  Donate once in a while and keep the development plus support going.  --  That's my opinion and I'm stickin' to it!

Offline abantecart

  • Administrator
  • Hero Member
  • *****
  • Posts: 4359
  • Karma: +298/-10
    • View Profile
    • Ideal Open Source Ecommerce Solution
Re: Uploading files to download section
« Reply #1 on: October 28, 2013, 10:58:14 PM »
Interesting. Can you post exact error you get?
Please  rate your experience or leave your review
We need your help to build better free open source ecommerce platform for everyone. See how you can help

Offline buddahboy

  • Full Member
  • ***
  • Posts: 234
  • Karma: +32/-0
    • View Profile
Re: Uploading files to download section
« Reply #2 on: October 28, 2013, 11:59:54 PM »
Thank you for your assistance - here is a screenshot of the message.  The file in question is 572mb, zip format

Appreciate your assistance. 

AbanteCart is one hell of a shopping cart.  Donate once in a while and keep the development plus support going.  --  That's my opinion and I'm stickin' to it!

Offline Basara

  • Administrator
  • Hero Member
  • *****
  • Posts: 5810
  • Karma: +274/-2
    • View Profile
Re: Uploading files to download section
« Reply #3 on: October 29, 2013, 03:06:56 AM »
Greetings,

My php.ini on the server allows for a max of 600mb and the php.ini within AbanteCart's directory is also set for 600mb - I see in AbanteCart under system settings  that I can upload up to 600mb (screenshot attached).  I try to upload a 572mb file and get an error message  600.04 MB  Error: True  -  the file is not 600 mb.   

Any thoughts? 

Thanks,
Ron

Hello. The file system allocates disk space in blocks or clusters, which typically range in size from 512 bytes to 32KB. The size occupied by the file is usually greater than its actual size, because it gets rounded up to a whole number of blocks.
Please try to upload a bit smaller file. Hope this is not a bug)))

Offline buddahboy

  • Full Member
  • ***
  • Posts: 234
  • Karma: +32/-0
    • View Profile
Re: Uploading files to download section
« Reply #4 on: October 29, 2013, 10:33:22 AM »
Hi Basara,

Thanks for taking the time to assist. 

This zip is a collection of volumes that are sold separately and while it is very large we have customers that buy it - I made a zip of 6 of the volumes and it came to 410MB and when uploading it to resources it showed indeed that it was rounded up to 430MB BUT it did begin to upload. 

Wanted to let you know that your thought was correct and that this is not a bug.   ;)

Once more, I appreciate the assistance - invaluable.  First site with AbanteCart and just love it BTW and reviewing it, sharing it - thanks again! 

All the best,
Ron
« Last Edit: October 29, 2013, 03:02:22 PM by buddahboy »
AbanteCart is one hell of a shopping cart.  Donate once in a while and keep the development plus support going.  --  That's my opinion and I'm stickin' to it!

Offline buddahboy

  • Full Member
  • ***
  • Posts: 234
  • Karma: +32/-0
    • View Profile
Re: Uploading files to download section
« Reply #5 on: October 29, 2013, 02:44:50 PM »
Greetings - I spoke too soon - - as mentioned my php.ini on the server is set to 600mb, the php.ini for AbanteCart is set for 600mb (images above) - went to upload a file that is 350mb and got the error message again (screen attached).  This is far below the limit so I'm hoping I can get some assistance here.  Worse come to worse can I upload it via FTP?  Don't know how I'd do that though but I'd like to use the resource upload function if I can. 

From error log:

2013-10-28 15:43:16 - warning:  AbanteCart core v.1.1.7 unlink(/home/xxxx/public_html/AbanteCart/resources/archive/18/7a/1.zip): No such file or directory in <b>/home/xxxx/public_html/AbanteCart/core/lib/resource_manager.php</b> on line <b>203</b>

2013-10-28 15:44:33 - runtime notice:  AbanteCart core v.1.1.7 Only variables should be passed by reference in <b>/home/xxxx/public_html/AbanteCart/core/engine/resources.php</b> on line <b>84</b>

2013-10-28 15:44:33 - error:  AbanteCart core v.1.1.7 Allowed memory size of 134217728 bytes exhausted (tried to allocate 69423006 bytes) in <b>/home/xxxx/public_html/AbanteCart/core/engine/dispatcher.php</b> on line <b>308</b>

Thanks much for any assistance,
Ron
« Last Edit: October 29, 2013, 03:00:41 PM by buddahboy »
AbanteCart is one hell of a shopping cart.  Donate once in a while and keep the development plus support going.  --  That's my opinion and I'm stickin' to it!

Offline abolabo

  • core-developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 2048
  • Karma: +319/-13
  • web for all, all for web!
    • View Profile
    • AbanteCart
Re: Uploading files to download section
« Reply #6 on: October 30, 2013, 07:08:37 AM »
Greetings - I spoke too soon - - as mentioned my php.ini on the server is set to 600mb, the php.ini for AbanteCart is set for 600mb (images above) - went to upload a file that is 350mb and got the error message again (screen attached).  This is far below the limit so I'm hoping I can get some assistance here.  Worse come to worse can I upload it via FTP?  Don't know how I'd do that though but I'd like to use the resource upload function if I can. 

From error log:

2013-10-28 15:43:16 - warning:  AbanteCart core v.1.1.7 unlink(/home/xxxx/public_html/AbanteCart/resources/archive/18/7a/1.zip): No such file or directory in <b>/home/xxxx/public_html/AbanteCart/core/lib/resource_manager.php</b> on line <b>203</b>

2013-10-28 15:44:33 - runtime notice:  AbanteCart core v.1.1.7 Only variables should be passed by reference in <b>/home/xxxx/public_html/AbanteCart/core/engine/resources.php</b> on line <b>84</b>

2013-10-28 15:44:33 - error:  AbanteCart core v.1.1.7 Allowed memory size of 134217728 bytes exhausted (tried to allocate 69423006 bytes) in <b>/home/xxxx/public_html/AbanteCart/core/engine/dispatcher.php</b> on line <b>308</b>

Thanks much for any assistance,
Ron

hello.
php have two directives that can to limit upload size of file: upload_max_filesize  and post_max_size. Check both via phpinfo(); function.
Also do not forget settings of upload file size on Abantecart settings page.


“No one is useless in this world who lightens the burdens of another.”
― Charles Dickens

Offline buddahboy

  • Full Member
  • ***
  • Posts: 234
  • Karma: +32/-0
    • View Profile
Re: Uploading files to download section
« Reply #7 on: October 30, 2013, 11:00:45 AM »
Good Day Abolabo,

If you look above, Oct. 28, you'll see a screenshot of the AbanteCart interface for system > settings and that files can be uploaded 600mb. 

A few days ago I had the changes made to both upload_max_filesize  and post_max_size to accommodate the same and still cannot upload large files over 100mb despite the changes made to the three files. 

Any other thoughts?  I could FTP if this is a bug or just won't work but don't know how to do that so when people buy the download the "download" function in My Account is associated with the file.  Would using the resource library "add image url or resource HTML" help as an alternative? 

Sure hope this can be straightened in some manner as I have quite a few files that are in the 250 - 350mb file range. 

Thanks for taking the time to assist me,
Ron
AbanteCart is one hell of a shopping cart.  Donate once in a while and keep the development plus support going.  --  That's my opinion and I'm stickin' to it!

Offline buddahboy

  • Full Member
  • ***
  • Posts: 234
  • Karma: +32/-0
    • View Profile
Re: Uploading large files to download section
« Reply #8 on: October 31, 2013, 11:30:00 AM »
Anyone have some thoughts on this?  Seems all the files are set correctly with size but just won't load.  Would really appreciate some help here if someone has a solution. 

Appreciate your assistance,
Ron
AbanteCart is one hell of a shopping cart.  Donate once in a while and keep the development plus support going.  --  That's my opinion and I'm stickin' to it!

Offline junkyard

  • Full Member
  • ***
  • Posts: 127
  • Karma: +25/-0
    • View Profile
Re: Uploading large files to download section
« Reply #9 on: October 31, 2013, 01:47:07 PM »
Quote
Allowed memory size of 134217728 bytes exhausted

With regard to this part of error,  it could be related to memory_limit = 134217728÷1024÷1024 = 128M
Not sure if raising this limit can help it or not,  though?..
See at http://php.net/manual/en/ini.core.php  :
----
[ post_max_size integer ]
Sets max size of post data allowed. This setting also affects file upload. To upload large files, this value must be larger than upload_max_filesize. If memory limit is enabled by your configure script, memory_limit also affects file uploading. Generally speaking, memory_limit should be larger than post_max_size.
-----
Also according to  https://kb.mediatemple.net/questions/1117/How+do+I+increase+the+PHP+upload+limits%3F#gs
----
If the upload_max_filesize is larger than post_max_size, you must increase post_max_size so that it is bigger than upload_max_size.
If the value of post_max_size is larger than memory_limit, you must increase memory_limit so that it is larger than post_max_size.
----
    Also check if there are any limits present for  max_input_time  or max_execution_time (if any).

Finally, if nothing helps, you could post your ~/public_html/php.ini so that the experts could see it.
And check if there are other php.ini files messing around in your directories, here is one article that mentions how there could be many php.ini
    http://www.a2hosting.com/kb/developer-corner/php/custom-php.ini-files
(also .htaccess files might have upload size limits).


Offline buddahboy

  • Full Member
  • ***
  • Posts: 234
  • Karma: +32/-0
    • View Profile
Re: Uploading large files to download section
« Reply #10 on: October 31, 2013, 02:35:31 PM »
Thanks Junkyard -

" it could be related to memory_limit = 134217728÷1024÷1024 = 128M" - I'll check that out but I think it is already set to that value, but not sure. 

"... upload_max_filesize is larger than post_max_size, you must increase ..."
Both are set for 600mb as is the AbanteCart php.ini and the system > settings > system field also indicates a 600mb capability rather than the previous 100mb. 

"... max_input_time  or max_execution_time..."  don't think there are but will check it out just the same. 

Thanks for the advice, I'll do some more investigating and see - will post results here nonetheless. 

All the best
Ron
AbanteCart is one hell of a shopping cart.  Donate once in a while and keep the development plus support going.  --  That's my opinion and I'm stickin' to it!

Offline junkyard

  • Full Member
  • ***
  • Posts: 127
  • Karma: +25/-0
    • View Profile
Re: Uploading large files to download section
« Reply #11 on: October 31, 2013, 02:40:25 PM »
Quote
128M" - I'll check that out but I think it is already set to that value
Yeah but apparently this isn't enough -- try raising it further to 256MB and see if it makes the difference. The php script used for uploading files could be that memory hungry.. Cheers

Offline buddahboy

  • Full Member
  • ***
  • Posts: 234
  • Karma: +32/-0
    • View Profile
Re: Uploading large files to download section
« Reply #12 on: October 31, 2013, 02:46:17 PM »
Thanks again - I'll certainly try that, think you may be on to something. 

Will report back so others have a point of reference as well. 

All the best
Ron
AbanteCart is one hell of a shopping cart.  Donate once in a while and keep the development plus support going.  --  That's my opinion and I'm stickin' to it!

Offline buddahboy

  • Full Member
  • ***
  • Posts: 234
  • Karma: +32/-0
    • View Profile
Re: Uploading large files to download section
« Reply #13 on: October 31, 2013, 03:42:02 PM »
JunkYard wrote (in part):
" it could be related to memory_limit = 134217728÷1024÷1024 = 128M"

memory upped to 196m and tried but bummed out after about 2/3 - error log:

2013-10-31 9:27:38 - warning:  AbanteCart core v.1.1.7 Invalid argument supplied for foreach() in <b>/home/xxxx/public_html/AbanteCart/admin/controller/pages/design/blocks.php</b> on line <b>552</b>

2013-10-31 9:28:15 - warning:  AbanteCart core v.1.1.7 Invalid argument supplied for foreach() in <b>/home/xxxx/public_html/AbanteCart/admin/controller/pages/design/blocks.php</b> on line <b>552</b>

In the AbanteCart php.ini there are 2 lines that I just noticed:
memory_limit = 64M;
max_execution_time = 18000;

wonder if changing memory limit to the 196m as the server side php.ini would help? 
if execution time is in seconds then that is 300 minutes and more than enough time be tons. 

Any thoughts? 

Thanks again
Ron
AbanteCart is one hell of a shopping cart.  Donate once in a while and keep the development plus support going.  --  That's my opinion and I'm stickin' to it!

Offline junkyard

  • Full Member
  • ***
  • Posts: 127
  • Karma: +25/-0
    • View Profile
Re: Uploading large files to download section
« Reply #14 on: October 31, 2013, 05:24:53 PM »
Quote
memory upped to 196m and tried but bummed out after about 2/3 - error log
The 2 warnings seem to be not related, and the memory limit error must have gone. 
Does the 2/3 estimate mean it upped a wee bit, or there was no progress at all?

Quote
wonder if changing memory limit to the 196m as the server side php.ini would help?
FWIW, the files uploading limitation is set by the php.ini file closest to the cart's php script doing upload. Most likely it is
~/public_html/AbanteCart/php.ini.    Do you also have /public_html/php.ini ?

 

Powered by SMFPacks Social Login Mod