I am trying to build a site with Joomla 2.5.4 and K2 2.5.7.
Attaching images causes a blank screen. Not all images do this, but many do and there does not seem to be a consistent relationship regarding the size in kb or pixels. The problem occurs for images as small as 200px and 50kb.
Turning on errors gives the following error:
[code type=php-brief]Fatal error: Out of memory (allocated 11272192) (tried to allocate 3724 bytes) in /homepages/15/d104641567/htdocs/joomla25/administrator/components/com_k2/lib/class.upload.php on line 3161[/code]
Line 3161 is the call:
Attaching images causes a blank screen. Not all images do this, but many do and there does not seem to be a consistent relationship regarding the size in kb or pixels. The problem occurs for images as small as 200px and 50kb.
Turning on errors gives the following error:
[code type=php-brief]Fatal error: Out of memory (allocated 11272192) (tried to allocate 3724 bytes) in /homepages/15/d104641567/htdocs/joomla25/administrator/components/com_k2/lib/class.upload.php on line 3161[/code]
Line 3161 is the call:
14 years 5 months ago #66919
First check to be sure mb_string encoding is enabled on your server, and also increase the php timeout value
Topic Author
14 years 5 months ago #66920
max_execution_time is set to 50000, and I've never seen an error associated with execution time. PHP was configured using '--enable-mbstring=all'
mbstring
Multibyte Support enabled
Multibyte string engine libmbfl
HTTP input encoding translation disabled
libmbfl version 1.3.2
mbstring
Multibyte Support enabled
Multibyte string engine libmbfl
HTTP input encoding translation disabled
libmbfl version 1.3.2
Topic Author
14 years 5 months ago #66921
Problem solved. I think. It seems that though the server would return a value of 90M when queried about the memory_limit, the actual memory limit was 10.75M. It's somewhat disconcerting to poll the memory limit variable right before the line that causes the error and find that you should have 8 times more memory. I changed server packages and now the problem is gone.
14 years 4 months ago #66922
Fatal error: Allowed memory size of 16777216 bytes exhausted (tried to allocate 900 bytes) in /.........../joomla/administrator/components/com_k2/lib/class.upload.php on line 3161
Same mistake... same problem... What about solution?
Does anybody may help, please?
Put your hands on your keyboard and feel the warm of my honest thank.
Litho
Same mistake... same problem... What about solution?
Does anybody may help, please?
Put your hands on your keyboard and feel the warm of my honest thank.
Litho
14 years 4 months ago #66923
@Thomas
Your server seems to have a memory limit of 16MB which is verry little. You need to increase it. Otherwise K2 won't be able to upload and resize images.
Your server seems to have a memory limit of 16MB which is verry little. You need to increase it. Otherwise K2 won't be able to upload and resize images.
14 years 4 months ago #66924
David, I'm probably experience the same problem, I have 64Mb memory limit (which I suppose should be enough) and the same error occures. Could you specify the solution more in detailes? What should I check or ask my hosting provider to change? Great thanks in advance!
14 years 4 months ago #66925
@Olga
It's not true that 64MB are enough. I mean it depends on the image. For most of the cases 64MB are enough indeed. But if you are trying to upload a really large image 64MB are not enough.
It's not true that 64MB are enough. I mean it depends on the image. For most of the cases 64MB are enough indeed. But if you are trying to upload a really large image 64MB are not enough.
14 years 4 months ago #66926
Who is your host?
If it's Site5, they have recently imposed a CPU time limit of 5 sec across their entire fleet and this cannot be overridden with PHP.INI.
If I can identify what script is doing the image upload and hitting the CPU limit, they will apparently increase the CPU time for that one process to 25 secs. I am trying to track this down.
If it's Site5, they have recently imposed a CPU time limit of 5 sec across their entire fleet and this cannot be overridden with PHP.INI.
If I can identify what script is doing the image upload and hitting the CPU limit, they will apparently increase the CPU time for that one process to 25 secs. I am trying to track this down.