Fatal error: Out of memory... in the back end

Phoca Gallery - image gallery extension
aenaos
Phoca Newbie
Phoca Newbie
Posts: 8
Joined: 29 Oct 2009, 16:14

Fatal error: Out of memory... in the back end

Post by aenaos »

Hello

When I choose Components>Phoca Gallery>categories from the back end I see this error

Fatal error: Out of memory (allocated 38797312) (tried to allocate 122880 bytes) in /home/....../public_html/libraries/phpgacl/gacl_api.php on line 3391

Everything else in front and back end works fine
I made all the fixes in server side: more memory etc, sql optimization without solution.
I have the latest versions of Phoca 2.8.0 and joomla 1.5.23
There are about 25.000 images and 2.500 categories in the site right now.

Any idea to solve the problem?
thank you.

PHP Built on: Linux srv01.panoramapress.gr 2.6.18-128.4.1.el5 #1 SMP Tue Aug 4 20:19:25 EDT 2009 x86_64
Database Version: 5.0.92-community
Database Collation: utf8_general_ci
PHP Version: 5.3.4
Web Server: Apache/2.2.17 (Unix) mod_ssl/2.2.17 OpenSSL/0.9.8e-fips-rhel5 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635 mod_perl/2.0.4 Perl/v5.8.8
Web Server to PHP interface: cgi-fcgi
Joomla! Version: Joomla! 1.5.23 Stable [ senu takaa ama baji ] 04-March-2011 18:00 GMT
User Agent: Mozilla/5.0 (Windows NT 6.1; rv:6.0.2) Gecko/20100101 Firefox/6.0.2
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49150
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Fatal error: Out of memory... in the back end

Post by Jan »

Hi, try to search similar posts in this forum, as the options to solve it is written many times here:

- increase memory limit
- or upload images with smaller size
- and retest all recommended settings in Phoca Gallery Info panel.

Jan
If you find Phoca extensions useful, please support the project
aenaos
Phoca Newbie
Phoca Newbie
Posts: 8
Joined: 29 Oct 2009, 16:14

Re: Fatal error: Out of memory... in the back end

Post by aenaos »

Jan wrote:Hi, try to search similar posts in this forum, as the options to solve it is written many times here:

- increase memory limit
- or upload images with smaller size
- and retest all recommended settings in Phoca Gallery Info panel.

Jan
Hello
- I checked for posts with similar errors and tried to follow them
- Increased php Memory limit to 120M
- All images are checked to have maximum 600px wide
- made various combinations in Phoca parameters
but the error persist.

Something else to be checked?

And one question
Why the problem in categories list? Categories are about 2.500.
Images list have thumbnails and are 25.000 entries, and works fine.

Thank you
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49150
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Fatal error: Out of memory... in the back end

Post by Jan »

Hi, in such case try to enable pagination thumbanail creating:
https://www.phoca.cz/documents/2-phoca-g ... -menu-item
https://www.phoca.cz/documents/2-phoca-g ... parameters

Categories vs. Images - it is explained many times in the forum. Images are using pagination - so in fact your server load at time only e.g. 20 items from database.

Categories are stored in tree - so you need to load all them from database and create a tree - this is why loading categories can be time demanding - this is common coding issue.

Jan
If you find Phoca extensions useful, please support the project
aenaos
Phoca Newbie
Phoca Newbie
Posts: 8
Joined: 29 Oct 2009, 16:14

Re: Fatal error: Out of memory... in the back end

Post by aenaos »

Thanks for your help Jan

The pagination thumbnail creating is always enabled.

The error stopped only after deleting (through phpMyadmin) 30 categories.
So I suppose that the problem will show up again in the near future after adding again some categories.

Taking into account that the phoca categories (in theory) could be near unlimited , the problem is that the server cannot handle all these categories and have a certain limit.
Is that correct ?
How can we set up the server to handle big numbers of categories?

Regards
George
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49150
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Fatal error: Out of memory... in the back end

Post by Jan »

HI, seems the only one solution is increasing the memory :-(

Jan
If you find Phoca extensions useful, please support the project
whph
Phoca Member
Phoca Member
Posts: 15
Joined: 01 Mar 2008, 18:57

New hint: Fatal error: Out of memory... in the back end

Post by whph »

Hi Jan, hi everybody

I stumbled across the same problem with fatal error, but made an observation.

I use Phocagallery 3.0.2 and Joomla! 1.6.6.

I could upload some pictures and create the thumbnails in one category, but then in another category I received this error:

Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 11328 bytes) in /home/httpd/vhosts/XXX/subdomains/test/httpdocs/administrator/components/com_phocagallery
/libraries/phocagallery/image/imagemagic.php on line 214

Just before this error was shown other lines flickered over the screen. I could capture them in a screenshot: [img][/img]

Basically, in geo.php occurred a division by zero on these lines:
[code]
$lat = $GPSLatDeg[0]/$GPSLatDeg[1]+
($GPSLatMin[0]/$GPSLatMin[1])/60+
($GPSLatSec[0]/$GPSLatSec[1])/3600;
$long = $GPSLonDeg[0]/$GPSLonDeg[1]+
($GPSLonMin[0]/$GPSLonMin[1])/60+
($GPSLonSec[0]/$GPSLonSec[1])/3600;
[/code]

I wonder how this can happen. Maybe this is the reason for all the problems!?

Thanks for looking into it.

Best regards,
Raphael
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49150
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Fatal error: Out of memory... in the back end

Post by Jan »

Hi, the division by zero should not run a memory problem, but see:
viewtopic.php?f=11&t=15542#p62769

Jan
If you find Phoca extensions useful, please support the project
whph
Phoca Member
Phoca Member
Posts: 15
Joined: 01 Mar 2008, 18:57

Re: Fatal error: Out of memory... in the back end

Post by whph »

Thanks a lot for giving feedback and of course for developing the component!

Raphael
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49150
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Fatal error: Out of memory... in the back end

Post by Jan »

The division by zero should be fixed in 3.1:
https://www.phoca.cz/news/30-phoca-news/ ... a-released

Jan
If you find Phoca extensions useful, please support the project
Post Reply