XML Sitemap can slow drupal considerably

robertlam - April 13, 2008 - 21:04

XML Sitemap can slow drupal considerably.

I install XML Sitemap 5.x-1.4. I enable all five module names; XML Sitemap, XML Sitemap Engines, XML Sitemap Node, XML Sitemap Term, XML Sitemap User.

When I try to create content it can take up to 20secs and frequently get the following error message. (Even after migrate from MYISAM to INNODB.)

"Warning: MySQL server has gone away query: watchdog INSERT INTO watchdog (uid, type, message, severity, link, location, referer, hostname, timestamp) VALUES (1, 'php', 'MySQL server has gone away\nquery: variable_set\nDELETE FROM variable WHERE name = 'xmlsitemap_changed' in"

After I remove everything but XML Sitemap . It takes less than 3seconds.

BTW I am using a shared host at Godaddy.

You can go to my site to try the speed. I have enable Normal page cache & CSS (this reduces page load time from 5seconds to 2-3seconds).

P.S. My site is not for the faint hearted.
www.swearpidia.com

I am a drupal rookie. However I feel drupal use too many database queries even for a simple page. I find digg which I think is drupal (right?) very slow. It takes 10seconds to submit a page.

What do you think?

=-=

VeryMisunderstood - April 13, 2008 - 21:13

I think if you are having a problem with a specific module you should file a report on that module.

If your host can handle the amount of queries drupal uses, find a new host or use the devel.module to help you figure out what is going on with your site.

_____________________________________________________________________
My posts & comments are usually dripping with sarcasm.
If you ask nicely I'll give you a towel : )

godaddy

rernst - April 13, 2008 - 21:28

Godaddy shared hosting is very slow and miserable. And seems very slow to begin with.

I don't think it's that drupal makes too many queries, it's that shared hosting hasn't evolved to keep up :S

devel.module

robertlam - April 13, 2008 - 21:53

Thank you for all the comments.

I am using devel. But I am not able to pin point the problematic query. I think devel list queries that generate the output page. However the delay is caused by the update / create sql queries before that.

BTW Pro Drupal Development book is a great help.

digg is not drupal...

rernst - April 13, 2008 - 21:25

Digg does not use Drupal.

Shared hosting is very slow to begin with. But you've done a good job by pointing out the time difference.

Here's a place you can start. Disable each one of the XML Sitemap submodules one-by-one and see which is causing the slowdown.

If we narrow it down to a particular submodule (or perhaps the main module...) it will be an easier problem to corner.

I found something interesting:
http://drupal.org/node/245185

Which means you should try the _user module first. Does your site have lots of users?

 
 

Drupal is a registered trademark of Dries Buytaert.