"Fatal error: Allowed memory size of x bytes exhausted (tried to allocate x bytes) in /*******.inc on line xxx"
Many, many users are raising issues around these error messages. It would be the hugest improvement to have a step-by-step troubleshooting guide for dealing with this. If there is one already, it is not prominent in search results. And it needs to be pitched at non-programming users (we are not going into our php.ini files anytime soon).
For example: What do I do if I can't increase my php memory with my host?
Debate varies around the particular problems of each error. And often, responses lead us off to other nodes, with the reply: "you need to allocate more memory." It seems that, different module contributors are kindly attempting to answer the problem on their own - where it is a drupal-wide issue.
---------------------------------------------------------------------------------------
As a secondary issue - this seems to be a big problem, that we need more and more memory to process our sites. Is anything to be done about it?
Myself and a crowd of others will be really helped out by some advice on this issue.
Comments
Comment #1
leehunter commentedThere's a page in the troubleshooting FAQ http://drupal.org/node/76156.
Does this need to be expanded?
Comment #2
eff_shaped commentedThanks for responding, LeeHunter,
well... I think I did see that page the first time I got the errors, and took it's advice (by requesting it with my host - I can't do it myself).
If that's the official documentation about such errors, could it be made more prominent in search results using those keywords? At the moment it looks like all the other results; there are a million issues that cloud the water.
I guess it could be expanded, to answer further questions: If I get similar errors (after adding more modules for instance) what can I do? Refresh the page? Run update.php a few times? Run cron? Clear cache? Wait 24 hours? Just go without the modules? Is there a recommended approach/procedure? Does the detailed wording of the error make any difference?
Could there be some guidance on which module combos will fit into which sizes? eg, if I want CCK, Views, Devel and a bunch other heavy hitters, what php memory sizes do I need?
Is there a more appropriate place to submit the issue of increasing php memory demands?
I got my host to increase php memory up to 32Mb. Which they say is my maximum.
Since that php memory increase, I've added more modules (I'm up to around 34 installed now). And I'm getting errors again. The latest try was to add Devel module; I've just unistalled it.
I saw a comment by NancyDru, that she does it all with 8Mb. What's her secret? (haha - can't find that post to reference now...)
Sorry about the avalanche of questions. Appreciate any enlightenment.
Comment #3
nancydruWell, first, that was Drupal 5 - not 6. Plus it is on a site without Views or CCK, maybe even without Image. Certainly by many standards, it would be considered a tiny number of modules.
If you are doing Drupal 6 with CCK and Views, 32Mb is getting tight. Add in other modules and you're really pushing it. And image handling stuff will easily push you over a 32Mb limit. There is virtually no way with video support.
My current host starts Drupal accounts out with 96MB, so I have no problems with limits any more.
Also, my first suggestion is to do all your testing on a local copy of your site. I would NEVER, EVER put Devel on a live site.
If your host think you can get by with 32MB, have them put up a test site of their own with Imagecache installed. It will complain in anything less than 96Mb.
I keep seeing the Drupal-gods saying that "Views is the way of the future" (and of course Fields, aka CCK, is now in D7). This cannot happen with hosts that still limit people to 32Mb.
Comment #4
leehunter commentedNancydru writes "It will complain in anything less than 96Mb."
Wow the system requirements page is still optimistically talking about a measly +16MB (http://drupal.org/requirements). Looks like we need a reality check there.
Comment #5
nancydruIt was hell getting it changed to that for D6... But, yes, with the increasing push for CCK and Views there is no way 16M is enough for anyone. Frankly, we shouldn't be saying anything less than 64M for a realistic site. It might be possible to run install.php in 16M, but not much else.
Comment #6
leehunter commentedWell if that's the case (and as eff_shaped points out this does seem to be causing a lot of grief) we at least need to make the system requirements more realistic.
This is the current version:
"PHP memory of 16 MB or higher for a default Drupal 6 installation (8 MB or higher may be sufficient for default installations of earlier versions). Depending on your site's use of custom or contributed modules, your PHP memory limit may need to be increased beyond 16 MB. "
How about we change it to:
"PHP memory requirements can vary significantly depending on your use of modules. While 16 MB may be sufficient for a default Drupal 6 installation, a production site with a number of modules enabled (CCK, Views etc.) could require 64 MB and some installations may require as much as 96 MB. If you are using a hosting service it is important to verify that your host can provide sufficient memory for the set of modules you are deploying."
Comment #7
nancydruHow about:
One user of some of my modules has recently reported memory problems with 256M...
Would it be appropriate to link to some page that I am sure exists somewhere that describes different hosting types (preferably without editorial bias)?
Has anyone worked out any real requirements for Drupal 7 yet? IMHO, it is time we really start publishing that so that hosts can be pushed to be ready in time for 7.x to roll out.
Comment #8
leehunter commentedThat sounds good to me. I've made the change to the requirements page.
I suspect some of the hosting services might not be very happy but if that's how much memory it takes to run a typical site we have to give people a proper heads up.
Comment #9
nancydruYeah, a lot of hosts are not ready for D7, so the more notice the better.
FYI, the page should also mention D7's need for PDO.
Comment #10
eff_shaped commentedThanks for making the update, LeeHunter;
And for joining the debate, NancyDru.
Now I just have to work on getting me some more allocation... *sigh*
Comment #11
MGParisi commentedI would like to add that any additional information that you want to add about this issue should be located around or at the WSOD topics.
I think everyone is happy though, and Im systematically going through the ticket list, so Im marking as fixed unless someone objects!
Comment #12
eff_shaped commentedWSOD = White Screen of Death.
I had no idea there was a whole topic area for this. Thanks for info.