skjaiswal1991 / smart-lencioni-image-resizer

Automatically exported from code.google.com/p/smart-lencioni-image-resizer
GNU General Public License v3.0
0 stars 0 forks source link

PHP Allowed memory size exhausted #25

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. New Install, 1st attempt at image resize. 

What is the expected output? What do you see instead?

expected image, nothing output.

What version of the product are you using? On what operating system?
2.0b3
Apache 2.2.2 Fedora
PHP 5.1.6

Please provide any additional information below.

Domain replaced with xxxxxxxx

from access log
GET /slir/h166/content/artists/kb/1.jpg HTTP/1.1" 200 175 
"http://xxxxxxxx/index.php?load=artists&artist=kb&section=hiresphotos" 
"Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.2) Gecko/20100115 
Firefox/3.6 ( .NET CLR 3.5.30729)

from error log
PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to 
allocate 11392 bytes) in 
/var/www/vhosts/xxxxxxxx/httpdocs/slir/slirimage.class.php on line 384, 
referer: http://xxxxxxxxx/index.php?load=artists&artist=kb&section=hiresphotos 

nothing in slir-error-log
nothing in cache

Original issue reported on code.google.com by martin.r...@gmail.com on 27 Sep 2010 at 8:31

GoogleCodeExporter commented 8 years ago
GD Version - bundled (2.0.34 compatible) 

Original comment by martin.r...@gmail.com on 27 Sep 2010 at 8:35

GoogleCodeExporter commented 8 years ago
What are the dimensions of the image you were resizing? Could you post a link 
to the source image?

The amount of memory that SLIR consumes is related to the size of the source 
image. You could either try using a smaller source image or increasing the 
memory limit in your slir-config.php file 
http://code.google.com/p/smart-lencioni-image-resizer/source/browse/trunk/slir-c
onfig-sample.php?spec=svn106&r=92#56

Original comment by joe.lencioni on 27 Sep 2010 at 2:05

GoogleCodeExporter commented 8 years ago
Hi, 

One of the original images was nearly 5MB at 
http://www.maxinerobertson.com/content/artists/mp/3.jpg
and I just wanted to generate thumbnails.

I tried imagecreatefromjpeg() on a windows installation I could control. I 
Found that I was running out of memory with PHP memory_limit = 40M, I increased 
this to 256MB and I could then get the GD functions to work.

I am unlikely to get the original hosted service to increase their limit from 
32MB so have ended up resizing the images on my home machine and ftp'ing the 
results to the producetion server. I would have preferred to use SLIR but this 
alternative meets my immediate needs.

Thanks for your time.

Original comment by martin.r...@gmail.com on 28 Sep 2010 at 10:20

GoogleCodeExporter commented 8 years ago

Original comment by joe.lencioni on 12 Nov 2010 at 8:45