1

I'm using Drupal with many modules because I need a lot of functionalities such as Newsletter, Taxonomy menus, Embed Videos.. and many other modules.

I get a fatal error when I enable all of them, but the point is that I'm using my development server with 128M of php memory.

So, I'm wondering... is basically impossible to run all these modules together in Drupal, or am I missing something ?

thanks

Update: this is the error message I get:

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 30220918 bytes) in /includes/bootstrap.inc on line 840

aneuryzm
  • 63,052
  • 100
  • 273
  • 488
  • Investigate memory leacks via devel and other tools. 128M usually enough even for 100 commonly used modules at one site... – Nikit Jul 02 '10 at 22:35
  • A fatal error of what? One of those modules could have some dumb bug like a call time pass by reference or something simple. – Kevin Jul 02 '10 at 22:42
  • are you running custom modules? check them first. it might happen that you are loading nodes or users without properly getting rid of them... – Capi Etheriel Jul 02 '10 at 23:51
  • thanks, how can I know how much memory each module take ? – aneuryzm Jul 03 '10 at 07:10
  • You could use the devel module to watch the database query or run apache bench against your site as adjust some setting (modules) to get an idea of how your site performs. – Rimian Jul 03 '10 at 09:53
  • Do you specifically get a memory exceeded fatal error? You should start with the core drupal and then enable the other modules one by one to see exactly when do you get the error. – abhaga Jul 03 '10 at 18:16

3 Answers3

2

I usually up the php memory limit in the setting file to get round this. Check out the article below.

http://drupal.org/node/207036

1

Following up from some of the comments made.

Drupal can run with well over 100 modules and thousands of nodes and millions of users, in 128 mb.

However some modules or combination of modules may misbehave. The most likely culprit is a home grown module, or a module which is either in beta or doesn’t have a lot of users. As people have said in the comments try disabling modules.

Alternatively if you have your development environment set up correctly put a breakpoint in bootstrap.inc to work out what it is doing at that point.

On my local environment line 840 in bootstrap.inc is in the watchdog function, so you may want to check your log. You could post what is around line 840 in the question.

Jeremy French
  • 11,707
  • 6
  • 46
  • 71
  • well, I actually get the error, then when I refresh the module page, I see that the module has been enabled, instead. Despite of the error message – aneuryzm Jul 05 '10 at 12:57
  • Enabling modules can trigger an install script running and also does a cache clear which results in a menu rebuild. You may want to check your site is ok after a cache clear. – Jeremy French Jul 05 '10 at 12:59
  • yeah I performed several times cache clear, everything seems ok. I sometimes get the error when I add a new module – aneuryzm Jul 05 '10 at 17:27
0

Edit the sites/default/settings.php

ini_set('memory_limit', '96M');

set memory limit what ever u need

Prabin Tp
  • 758
  • 6
  • 15