#2816 Fatal Error Allowed memory size


with several functions I get the error:
Fatal error: Allowed memory size of 42991616 bytes exhausted (tried to allocate 741 bytes) in /var/www/web219/html/ahnen/phpgedview/includes/functions/functions.php on line 663
This could be any request to read out SQL-Tables. The PHP-Limit at Server is 48 MB, Max.execution time 30, The Provider supports PHP 5, but I don't know witch excact version.
As attachment i add the config.php
Thanks in advance for the support


  • Bodo

    Bodo - 2010-06-12


  • ggpauly

    ggpauly - 2010-06-19

    This comes up frequently.

    You should increase the memory limit in your config.php file. The current setting of 41M is not sufficient for operations on larger Gedcoms or with large media collections. My ISP allows 90M or more, I set pgv to 128M if I can. If your ISP allows 48M, I'd use all of that.

    You didn't mention which version of PGV you're using. The latest version is more efficient at importing Gedcoms, so the error should not occur during that operation so frequently.

    All that said, I agree that this is a bug. The problem is that it's many bugs - there are, as you indicate, several places to run out of memory.

    I have a patch for one - searches. The patch limits the approximate number of records returned and warns the user that the limit was reached. 90M memory allows 1000 records, which is more than you'd want to deal with for most searches. Unpatched the search returns an error message after a long delay, a worse outcome. Generally the user would want to turn around and do a more limited search without even reviewing the 1000 results. This patch involved several files and needs to be ported to the trunk before submission. It also requires a config file entry, which I do manually but should be added to the UI for the patch. Maybe it could run off the memory allocation size.

    Which operations did you run into out-of-memory errors on?

  • Stephen Arnold

    Stephen Arnold - 2010-06-25

    This should have gone in HELP forum, and not BUGS. Please close this bug yourself as INVALID. There are no programmers to do this here, at this time.

  • Bodo

    Bodo - 2010-06-26

    The problem is, I only get 48 MB by the provider. One typical place to get the error is a request for media-files. in my gedcom are about 8000 media files. I have no chance to filter for a media-file. The file could only be read with the related individual. I use PGV 4.2.3. If You like to check, please go to:
    and use the gedcom "Kirchenbücher Obergeis". If You need, I can give access by request.
    Thanks for the help

  • Stephen Arnold

    Stephen Arnold - 2010-06-26

    Still - NOT A BUG.
    Media management, particularly if you have not carefully kept files to under 100k, can consume inordinate amounts of memory. Compounded further with the nearly 8,000 media objects. 48mb will never suffice. I use 1gb, but I have 80,000 INDI's and 4k MO.

    Please mark this thread as INVALID, CLOSED. It is a problem with your system and not PGV.

  • Stephen Arnold

    Stephen Arnold - 2010-06-29

    One more time,
    Please mark this thread as INVALID, CLOSED. It is a problem with your system configuration and not with PGV.

  • ggpauly

    ggpauly - 2010-07-02

    Hi Bodo,

    I visited your site. Searching for Schade gives a 500 error after a long delay. in my experience on other servers the error can vary from try to try, but with a large enough result set resources will run out.

    This is in my opinion a bug. PGV should degrade more gracefully.

    I'm not sure I understand the details of your media file problem. In my installations of PGV 4.2.3 no media files are presented at first in the "Manage Multimedia" page. Could you filter and operate on that subset? Earlier PGV versions displayed (or tried to) all media files on this page. Maybe there's a configuration setting somewhere. Media file results should likewise be regulated so that confusing error messages are not presented, but that's another project. Generally, only admins are subjected to the vagaries of the Manage Media page, so it's a lower priority than the general search errors that may be encountered by unregistered visitors on many sites.

    I agree with Stephen that the resource allowance from your ISP is insufficient. 60M memory is the recommended minimum. Have you considered another ISP? There are some that advertise on the PGV homepage - http://phpgedview.net/. I have a conflict of interest so I won't make a public recommendation, you can contact me through paulyfamily.org if you're interested.

    When I get a chance I'll post a preliminary patch for 4.2.3 to limit search results.


  • Stephen Arnold

    Stephen Arnold - 2010-07-02

    Searching can be affected by many factors, most of which have nothing to do with PGV or your gedcom. The primary reason for a failure is a short timeout - 30 seconds or less - for a script. Next, you may not have you optimized your database and you may have mixed collations. Additionally, you may not have used the best collation for your data. The default iSAM in not necessarily the best. You can get better overall results from INNO-DB collation.

    Regardless, Please close this bug as there is no PGV bug involved in your issues.

  • Bodo

    Bodo - 2010-07-02

    This appears to be an issue with your site configuration, not a bug in PGV. You will get a much better response to your query by posting on the "Help" forum.

  • Bodo

    Bodo - 2010-07-02

    Hi Stefan
    thanks for Your help, I will check for another ISP, which is more pefect for PGV. I was believing, I had close this report already. Now I close it with response to the help forum. Still I like the program, because it has nice and helpfull features.

  • Bodo

    Bodo - 2010-07-02
    • milestone: --> v4.2.3
    • status: open --> closed

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks