Here's the entire error message...

Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 33532118 bytes) in /home/anxietyz/public_html/blogs/includes/database.mysql-common.inc on line 41

What modules/issues/configurations can cause this error and what are some of the things I can do to correct it?. It periodically happens when I try to login.

I'm running Drupal 6.2 with the following NON-core MODS...

Img
Img comments
Avatar Selection
BBCode
blogtheme
BUEditor (installed but disabled)
DB Maintenance
FCKeditor
jtooltips
LoginToboggan (installed but disabled)
Messenger
Nice Menus
Poormanscron
Trackback
Weather

I have ALL of the default/core modules activated EXCEPT the following...

Aggregator
Content translation
Locale
Path
PHP filter
Throttle

On all of these modules (core and otherwise) I've either used the default settings or configured them to reasonable levels/options.

Thanks so much.

- Regards, Steve

Comments

Well the error says you are out of memory. You php.ini settings have allocated 64 MB of memory as the maximum any script can consume - which doesn't seem to be enough. Error also says you need 32 more MB of memory for site to function - I would add 64.

So update php.ini memory_limit to 128 MB

Thanks for the quick reply. I asked my host about this and he tells me that I need to create an .htaccess file and change the memory there. Then he sends me to some Apache page with a lot of technical jargon on it. He also tells me that I'm currently set at 96mb,

I guess what I'd really like to do is rather than set a new limit, I'd rather just modify my settings or remove modules so that Drupal does not use so much memory in the first place. Short of that, I'd kind of like to know which of the mods I've listed are memory intensive so that I can disable them.

Any suggestions?

- Regards, Steve

You should install the devel module and display it's block that shows memory usage to see which functions/modules are using the most memory.

Thanks for the advice (I'll give it a shot). I set the search index to a much lower number of nodes to index, raised the php memory limit from 96mb to 128mb and deactivated the following mods...

Blog API
Color
Database logging
OpenID
Ping
Statistics
Syslog
DB Maintenance
jtooltips
Poormanscron
Trackback
LoginToboggan
BUEditor
Aggregator

It seems to have done the trick for now but I'm still getting that pesky "auto_increment" error in mysql which is driving me nut and kept me up half the night.

- Regards, Steve

I've got the same problem on Drupal 5.7, though I only have a very small number of modules activated:

Comment
Locale
Menu
Path
Search
Statistics
Taxonomy
Devel
Image (+assist, attach, gallery, import)
LightBox
FCKEditor
Pingback
JQueryUpdate
Views, ViewsUI
Poormanscron (!!)

It seems Poormanscron is causing the error, as the site runs flawlessly with it deactivated and Devel shows a memory usage of around 10-11 MB.

My maximum memory is set to 64mb and doing a manual run of cron.php shows:
- Memory used at devel_shutdown(): 60.7 MB
That seems like WAY too much and could explain why Poormanscron is crashing my site when activated (though I set its interval at 60 minutes)
Checking the logs it seems my manual cron run couldn't be completed ... I don't get it ... up until May 4th every run of Cron (even via Poormanscron) completed without problems.

Any ideas?

This is my site by the way: mulb.org

The memory error is the following:
Fatal error: Allowed memory size of 68157440 bytes exhausted (tried to allocate 54181618 bytes) in /www/htdocs/w0099b51/drupal/includes/common.inc on line 485

I think it's always line 485, which is:
list($split, $result->data) = explode("\r\n\r\n", $response, 2);

how many nodes on your site?

how large are the tables on your DB, ie: search, watchdog and the like, that cron would be used with ?

There's currently 340 nodes (because of the many images) but is that already too much for indexing with 64mb?

The table sizes in the database:
- search dataset (85KB - 330 entries)
- search index (373KB - 7500 entries)
- search dataset (146KB - 3300 entries)
- watchdog (64KB - 215 entries)

DB size is 2.5MB, 61 tables. The biggest table is locales_source (I guess that's my German locale) with 490KB and 3200 entries.

Judging from those values it doesn't really seem like a simple cron run should exceed 64MB ...

it doesn't really seem like a simple cron run should exceed 64MB ...

Agreed, but because it wasn't mentioned it was worth ruling out as a variable.

Well yeah, except it's not ruled out, as cron keeps getting stuck because of too little memory.
Now if the small database doesn't cause that, what could it be ?
Unfourtunately I really can't guess that from the error message ...
Since May 4th when everything was still going well, I also didn't change anything, except adding two simple nodes ...

I tried to run cron.php manually again but I'm always getting stuck with the above error.

max_execution_time is set to 30, would it help to bump that up?
I thought maybe indexing for the search module takes too long, but shutting the module off didn't change a thing.

The really weird thing is that cron.php wants some 50mb more than the provided 65, so it can't really be a problem of growing number of nodes or index size ... so why should cron.php need 120mb while the usually site operations happily run with 10-11mb ?

I meant ruling out the search table as being overly large and trying to index it.

you can of course bump up the execution time to see if it helps.

Beyond that I have no answer. I've never used poormans cron to know what effect it has on Drupal. I prefer a cronjob set up at the server over what poormanscron does.

I recall reading a few "cron stuck" type threads awhile back. It may help to seek them out.

the possibility of something having a duplicate of it's self,
going into a loop that eats up memory. Just a thought

Thanks strship47 for this advice. I was continually getting a fatal error and your comment alerted me to the fact that when I had set up an application as a web form I had not deleted the same application I had as a simple page. Both had the same name. Deleted the page version and problem soleved. Thanks again

I have the same error here
i am new drupal here what i should do

every time i clear the cash this error appear for me !!

Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 796289 bytes) in /home/content/q/a/t/qatar123/html/includes/database.mysqli.inc on line 309

means you must increase your memory on your server or speak with your host to do it.

If you are on the shared host and you configured correctly the php.ini for higher memory_limit then the solution is very simple you just need to copy the 'correct' php.ini to the installation folder of drush ; and drush will pick it up by default the next time it run , more details here.

Thank you