Fatal Error: Allowed Memory Size

UpdraftPlus Home Forums Paid support forum – UpdraftPlus backup plugin Fatal Error: Allowed Memory Size

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #133523
    Patrick
    Participant

    I have an ongoing problem with Updraft. I have set the default memory size for PHP to 4 gig. Still, every time I try to restore a site, I’m running into the same error –

    Unpacking backup… (backup_2015-11-05-1534_xxxxx_27c71c23ae00-uploads.zip, 992.2 Mb)

    Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 1830546 bytes) in /home/xxxxx/public_html/wp-admin/includes/class-pclzip.php on line 4219

    Clearly, the memory limit of 4 gig is far larger than the 992.2 Mb size of the uploads archive, but the problem NEVER goes away. I have submitted a support request but not heard anything back.

    It seems to me that large files should be able to be handled using block writes, rather than just trying to load the entire thing into RAM. Is there any reason that Updraft is not using block writes for handling larger archives?

    I have recommended Updraft to many of my users – most of whom have trusted me and are using the plugin. But all of those with anything more than about 300 meg in their uploads directory are now complaining about this continual problem.

    I do not want to remove the PHP memory limit, nor do I want to set it to such a high level that it allows bad PHP script to consume more RAM than is appropriate for a web server. There must be a solution to this and I need to figure it out because I’m getting a lot of embarassing complaints from my clients.

    Please advise.

    #133535
    udadmin
    Keymaster

    Hi Patrick,

    This post duplicates a support ticket which my colleague (also David) has already replied to. However, in case it helps, I’ll repeat it here:

    Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 1830546 bytes) in /home/xxxxx/public_html/wp-admin/includes/class-pclzip.php on line 4219

    According to that error message, your current memory limit is only “268435456 bytes” = 256 Mb. So, whatever you’ve done in attempting to raise it to 1Gb has not taken effect.

    This FAQ should help:

    How do I deal with “Fatal error: Allowed memory size of…” errors?

    Concerning how much memory is needed to unzip a zip file, the PHP zip engine requires as much spare memory as the largest single file in the zip file. By default, UD splits zips as soon as they go over 500Mb. Thus, the fact that you’ve apparently got a 992Mb zip file suggests that you’ve got a single file in there that’s approximately 500mb. So, you may need around 700Mb allocated to PHP to be able to unzip that, depending on how much is already in use for other parts of WordPress.

    But all of those with anything more than about 300 meg in their uploads directory are now complaining about this continual problem.

    I’m very surprised to hear that, as we’ve not seen any evidence of a common problem in our support queue – and we have customers backing up sites as large as 50 gigabytes (from what they’ve told us – UD doesn’t “phone home”). I’d recommend posting a full log file in the support channel for any problematic backup you’re having.

    David

    #133538
    Patrick
    Participant

    My mistake – I moved the lines to the top of the wp-config.php file and it’s working properly.

    I’m confused about why these lines don’t work at the bottom of the same file, though.

    Thanks for the help.

Viewing 3 posts - 1 through 3 (of 3 total)
  • The topic ‘Fatal Error: Allowed Memory Size’ is closed to new replies.