Closed (fixed)
Project:
XML sitemap
Version:
5.x-2.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
7 Mar 2008 at 21:54 UTC
Updated:
28 Sep 2011 at 13:10 UTC
Jump to comment: Most recent
After editing a term in my main vocabulary, Drupal outputted the following error:
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 3407854 bytes) in /var/www/drupal/modules/xmlsitemap/xmlsitemap.module on line 487
Whatever happened, I was also logged out after this error. However, the edits I made to the term were saved.
Regards, -asb
Comments
Comment #1
vm commentedTroubleshooting FAQ's section of the documentation area:
Fatal error: Allowed memory size of X bytes exhausted (tried to allocate Y bytes)...
may help.
Comment #2
asb commentedThanks,
sure is php.ini the first place to look. My current settings:
I simply don't want to increase memory_limit even higher, if possible.
Are there recommended settings for Drupal? What is sensible?
What values are other people using?
And yes, the error is reproducable. I assume, it is caused by a large vocabulary, but I couldn't find any suggestions about the size of a vocabulary, potential limitations of Drupal, etc.
Thanks & regards, -asb
Comment #3
vm commentedDependant on variables like how many contrib modules are in use & the like.
Comment #4
darren ohAt the moment, site maps are generated from a PHP array. The more links you have, the more memory it requires. For now I would recommend turning off "Submit site map when updated" on the search engines tab. Your site map will then be generated only on cron runs, hopefully within the memory limits. If it still exceeds the memory limit, you will experience issue 201644.
Comment #5
darren ohComment #6
darren ohComment #7
Rob T commentedThanks for the tip, Darren. Turning off the "Submit site map when updated" worked well for me.
Comment #8
kbahey commentedA site with over 42,000 nodes is experiencing this issue, even with 100MB, and I don't want to increase this further.
I am NOT getting the error in http://drupal.org/node/201644, hence reopening this one.
The site is already configured to Submit only on cron, but cron never completes. The only solution was to disable the xmlsitemap module.
Is there a way to generate the XML from a temporary file, instead of a memory array?
Comment #9
codepoet commentedSame issue with the 6.x-dev version. Subscribing.
Comment #10
asb commented> The site is already configured to Submit only on cron, but cron never completes. The only solution was to disable the xmlsitemap module.
Same problem here, php memory limit set to 96M, xmlsitemap module (and others) had to be disabled. Data about a site's structure needs to go into core so it can be utilized through an API by modules like xmlsitemap, sitemap, sitemenu and others working with the same set of data but presenting it differently. Other modules have similar problems, and IMHO it makes absolutely no sense if several developers try to reinvent the wheel for different, but similar modules.
Please have a look at maintenance/generateSitemap.php in any MediaWIki installation [1] how this is handled on medium to large sized high traffic sites.
Thanks & greetings, -asb
[1] http://www.mediawiki.org/wiki/Manual:GenerateSitemap.php
Comment #11
kbahey commented@asb
This should not be into core. Why? Because everyone wants to use it differently. Not all sites need it. Let core be lean, mean and clean.
A better option is to create a sitemap API which provides this functionality to modules that need it. Then modules can build on top of that. Something for Google, something for HTML sitemap page, something for menu navigation, ...etc.
If that API proves useful, it can then be considered for core, but can still be useful outside it (e.g. voting API, Userpoints API, ...etc.)
Now back to the original problem. Any ideas on how to reduce memory consumption by xmlsitemap?
Comment #12
pharma commentedWe have same problem . Any luck on this issue ?
Comment #13
vacilando commentedSubscribing...
Comment #14
wbosman commentedSubscribing
Comment #15
mcarrera commentedsubscribing
Comment #16
avpadernoI am changing the referring version to the one which gets the code fixed.
Comment #17
avpaderno@asb: Are you using some modules that change the cache used by Drupal to be kept in memory?
Is this the case for somebody else who has this issue?
Comment #18
avpadernoComment #19
pkej commentedI usually add ini_set( "memory_limit", "128M" ); in the settings.php file, a couple of places even to 256M.
Increase PHP memory limit is a must read.
Comment #20
pkej commentedSomeone changed the title while I was writing, so I change it back to what he wanted.
Comment #21
avpadernoComment #22
Anonymous (not verified) commented#503010: Close the 5.x-2.x-dev branch as unsupported
Comment #24
manumhndas commentedFatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 71 bytes) in my page
I got this error when i installed cart module how can i overcome this error? plz send me a solution.
Comment #25
Anonymous (not verified) commentedThis is a closed issue for 5.x-2.x-dev and is more than 2 years old. Open a new issue or look for one that is already open for the version you're using.