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

1.1.3 upgrade leaves "out of memory" fatal error - can't access admin

Discussion in 'Troubleshooting and Problems' started by sitwi, Jun 26, 2012.

  1. sitwi

    sitwi Active Member

    I've nicely tuned my Xenforo site over the last few weeks in preparation for go live, and today upgraded to 1.1.3.

    I haven't had a single hitch up until now, but after upgrading (apparently successfully), I'm no longer able to access admin.php.

    The Board itself works great, without a hitch, and I can even navigate around the admin area from a window which I'd left open prior to the upgrade. It's just the admin.php which I'm unable to reach.

    Here's the error message:

    Can anyone please help? I was just about ready to go live, as well! :(

    I'd really appreciate anyone's time. Thank you.
  2. HWS

    HWS Well-Known Member

    I would raise the memory settings in php.ini and try again.
  3. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Your memory_limit is very low. HWS is correct... you need to increase the limit. If you are on a shared server or don't have root access then you will need to ask your web host to increase the limit for you.
  4. sitwi

    sitwi Active Member

    Thanks for such a quick reply, HWS.

    This is the level of noob that you're dealing with, though, so I apologise if this is a stupid question - where do I locate this file? If it's not in the root, do I create one?

    (The error message seems to suggest a huge amount of activity somewhere, and I've no idea how that would be generated from one simple admin front page - but I should get it working before I start fretting about that!)

    Appreciate any further advice.
  5. HWS

    HWS Well-Known Member

    $ find / -name "php\.ini"
    should work if you are not on Windows.

    Usually it's in /etc/php.ini

    You may ask your server administrator to do this for you.
  6. duderuud

    duderuud Active Member

    On Ubuntu (12.04) it's /etc/php5/apache2
  7. sitwi

    sitwi Active Member

    Thanks guys - I'm way out of my depth with this one, I'm afraid. I've been right through and don't see a php.ini file. My understanding is that this file would only affect the folder in which it is placed - if I need to create one, could you please let me know into which folder I should put it?

    Do you have any sensible limits that I should include? Could it otherwise be set within the .htaccess?

    Sorry for so many questions.
  8. Ingenious

    Ingenious Well-Known Member

    I have one in my root folder (the folder above public_html) but have also put php.ini into inividual folders where I want different settings for different applications. I should add I am on shared hosting.

    In my php.ini which is a text file and edited using notepad etc. there is this line to set the memory:

    memory_limit = 128M ; Maximum amount of memory a script may consume (128MB)

    You could even just try a php.ini with just the above in, in your forum directory. This obviously assumes your server set up will read php.ini files in individual folders and apply them, I'm a newbie like yourself with this kind of thing. If you are on a VPS or dedicated then you'd have a master php.ini file as others have said above.
  9. sitwi

    sitwi Active Member

    Thanks all. I created a php.ini file for the root, containing simply:

    memory_limit = 128M
    The error message is now very slightly different:

    I even increased to 256MB, but no change. Any ideas? Appreciate the help so far.
  10. duderuud

    duderuud Active Member

    You should make a phpinfo file, that will show you where the php.ini is located on your server.
    Create a php file with the following content:
    Save and view that file in your web browser.
  11. sitwi

    sitwi Active Member

    Thank you, duderuud. Just did that, and some further research into 1&1, who are my hosts. Regardless of what I set within my php.ini, they cap the memory_limit at 90mb.

    Is there any way to get around this? It seems strange that the board itself is running smoothly, as is the rest of my ACP except for the front page. I just don't understand what's using so much memory!
  12. Sadik B

    Sadik B Well-Known Member

    Hi sitwi

    Changing the setting in php.ini is the right way of solving this as Jake and others have pointed out. However if you are finding that difficult to do, you can also do this.

    Inside your Library Folder there is config.php file. Open the file config.php and add this line right at the top.


    Remove the previously created changes in php.ini (which you must have done in the wrong place else it would have worked). By the way if you had made the change in php.ini in the right place, you still need to restart apache for the change to work. If all this seems too technical, don't bother and put the above line in config.php and it should solve your problem.
    HWS likes this.
  13. sitwi

    sitwi Active Member

    Thank you, Sadik. Same problem after implementing that, though - I do think my hosts are imposing their 90mb limit. I will get onto them about that. It's really strange to me that an upgrade might have suddenly cause the messages, as everything was running smoothly before and it's not a large site (maybe 60,000 posts and 2,000 members).

    Thanks again. Puzzled!
  14. Sadik B

    Sadik B Well-Known Member

    Yes that is possible. Your host can impose a hard memory limit. If they are imposing a 90MB limit, put 90M in config.php and see if that proves sufficient. But yes, xenforo should run fine on about 64M memory limit too for your board... so not sure what is requiring so much memory.
  15. sitwi

    sitwi Active Member

    No, me neither. Setting the limit to 90mb didn't change it. This is a huge disappointment as Xenforo seemed the perfect solution, but my hosts don't seem able to oblige.
  16. robdog

    robdog Well-Known Member

    You are definitely not getting to 90MB per PHP cycle. Just look at the error. It appears to die around 16MB. I have never used 1&1 so I have no idea if you have SSH access. Maybe submit a support ticket to 1&1 and tell them to max out this value in the PHP.ini file for you. Because you are definitely not hitting their limit.
  17. sitwi

    sitwi Active Member

    Thanks all for your generous help. I'm a little further forward with my hosts, who have explained that 90mb is across the whole package. I have maybe ten sites on my package with them, and that could be why 16mb is making it fall over.

    I'm going to try shifting my sites around and see if that makes any difference.
  18. Sadik B

    Sadik B Well-Known Member

    1&1 btw are a very notorious host. I would never advise anyone to take their shared packages.
    HWS likes this.
  19. sitwi

    sitwi Active Member

    In terms of security, Sadik? Customer service or tech help? I've had a few run-ins with them in the past (usually over the latter) but they've usually put themselves straight.
    SilverCircle likes this.
  20. We switched to In Motion Hosting from our other, less-than-friendly host, and they are outstanding hosts!! Friendly and very knowledgeable CS, 24/7, and usually have things solved in less time than the call takes!

Share This Page