1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.1 Finally Went Live... Now Memory Issues

Discussion in 'Troubleshooting and Problems' started by JRW-910, May 30, 2012.

  1. JRW-910

    JRW-910 Member

    I just moved an existing vB forum over to xF and I have having some issues:

    Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 71 bytes) in /home/site/public_html/library/Zend/Db/Statement/Mysqli.php on line 295

    Any ideas?

  2. Adam Howard

    Adam Howard Well-Known Member

    I've seen this on a few shared hosting providers. Add this to your .htaccess and see if this corrects the issue

    <IfModule mod_php5.c>
    php_value max_execution_time 60
    php_value max_input_time 90
    php_value memory_limit 256M
  3. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    I am curious what is using 128MB of memory. What page generates that error? Do you have any addons installed?
    TheVisitors likes this.
  4. JRW-910

    JRW-910 Member

    I do have a few addons installed. I can't even get into the cp right now.

    This is running on a VPS.

    The .htaccess didn't help.


  5. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Here are some library/config.php lines you can try:

    ini_set('memory_limit', -1);
    $config['enableListeners'] = 0;
    One disables the memory_limit. The other disables addons (listeners) which may be responsible for the memory usage.
  6. JRW-910

    JRW-910 Member

    I just tried that and got:

    Fatal error: Out of memory (allocated 259784704) (tried to allocate 78 bytes) in /home/site/public_html/library/Zend/Db/Statement/Mysqli.php on line 304

    I might have to get my old vB back up... this is killing me.

  7. JRW-910

    JRW-910 Member

    Something is really wrong here. I had xF up and running on a test site (on the same server) for over a month with no issues at all. I don't think the site gets enough traffic to cause this much of a problem.

    I am really disappointed right now. If I can't get this straightened out by the end of the today, I'm going to have to go back to vB.... as much as I hate to do it.

  8. MattW

    MattW Well-Known Member

    Is the VPS managed or unmanaged? What do you have set in your php.ini for the memory limit? How much memory does the VPS have?
  9. MGSteve

    MGSteve Well-Known Member

    To be fair, it doesn't matter what the VPS has, the script shouldn't be using 256mb of RAM!

    Sounds like there is a config or other related error in there. When you said you had it on a test site, was it installed in the exact same file location and you then did another import over the top of it? Or did you wipe the install folders and re-upload and then re-import?
  10. JRW-910

    JRW-910 Member

    Memory Limit 32M - Post Max Size 8M
    512MB DDR3 RAM

    I ran xF in a folder (called beta) and did all of the mods and styling on a blank database. I backed up that database and did an import of my vB4 data. Continued to work on the site. Then I moved all of the files to the root directory, did a fresh install of xF, loaded up the beta xF databse (pre import) and imported the most recent versions of the vB4 DB.

    Thanks for your help,

  11. MattW

    MattW Well-Known Member

    Totally agree! However, was just wondering if the amount php is being allowed to use could be increased to at least get something loading, as it looks like they can't even log into the ACP
  12. John55

    John55 Member

    Strange, I'm experiencing a similar thing.

    Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 327121840 bytes) in /public_html/library/XenForo/Template/Abstract.php(265) : eval()'d code on line 308

    It's led to a 500 internal server error, which I'm having my host (shared server) take a look at now.
  13. Slavik

    Slavik XenForo Moderator Staff Member

    Explain your install / transfer also please in as much detail as possible.
  14. JRW-910

    JRW-910 Member

    Well, I can't seem to get this working. I'm going to re-upload all of the files again and see what happens. If that doesn't fix the situation or I don't find something here, I guess I'll be back to vB buy tomorrow :(

  15. Ingenious

    Ingenious Well-Known Member

    Don't give up JRW - I know it's a PITA but the potential gains from swapping to Xenforo will be worth it. Also, have you submitted a proper support ticket to Xenforo so one of the developers can look at this and maybe advise?
  16. John55

    John55 Member

    It was installed by another person (SchmitzIT), but as I understand it....We went from Vbulletin 3.8.x to Xenforo 1.1.2 without a hitch. There are only two plug-ins installed (Xenporta and Robbo's Ad Manager), with a stock skin (colored changed). The site has been up and running for about a month or so.

    My host (which may be reading this thread) said this:

    For what it's worth, my site is image intensive, as users often post and attach photos of various sizes. Could that be it? Any ideas?

    JRW, I hope you don't mind me posting and sharing in problem solving this related issue. For what it's worth, Xenforo is a definite keeper from the month or so I've been using it...stick with it if you can.
    Sylar likes this.
  17. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Yeah it shouldn't be using that much memory. I can take a look if you give me a URL, admin login, and FTP login.
    Brent W likes this.
  18. MGSteve

    MGSteve Well-Known Member

    tbh, you both need to start support tickets for this, Mike (or someone else) needs to have hands on with the servers to work out what's going on in the code. Seeing as loads of others aren't reporting the same issue, we can rule out the software sort of, but it sounds like its a issue caused by the particular config on the servers.
  19. JRW-910

    JRW-910 Member

    PM sent!


  20. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

Share This Page