Hello,
I am currently experiencing very slow page loads on my website due to a few database queries that take an incredible amount of time. The most common are associated with the function DrupalDatabaseCache:set where queries like:
INSERT INTO cache_menu (cid, serialized, created, expire, data) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4)
and
UPDATE cache_bootstrap SET serialized=:db_update_placeholder_0, created=:db_update_placeholder_1, expire=:db_update_placeholder_2, data=:db_update_placeholder_3 WHERE ( (cid = :db_condition_placeholder_0) )
take ~2500ms and happen multiple times in the course of one page load. Typical pages look like this: "Executed 82 queries in 18043.09 ms.Page execution time was 20568.44 ms." I gathered this information using the Devel module.
In addition to this issue, it seems like there might be an issue with bootstrap.inc.
I ran several SSH commands including:
time php index.php and strace php index.php
Both commands output an error:
<b>Notice</b>: Undefined index: SCRIPT_NAME in <b>/home1/orianbre/public_html/swingsyndicatedance/includes/bootstrap.inc</b> on line <b>1379</b><br />
Here is the output from the trace:
<b>Notice</b>: Undefined index: REMOTE_ADDR in <b>/home1/orianbre/public_html/swingsyndicatedance/includes/bootstrap.inc</b> on line <b>2488</b><br />
) = 160
poll([{fd=3, events=POLLIN|POLLPRI}], 1, 0) = 0 (Timeout)
write(3, "\25\2\0\0\3INSERT INTO watchdog (uid, "..., 537) = 537
read(3, "\t\0\0\1\0\1\374a\2\2\0\0\0", 16384) = 13
chdir("/home1/orianbre/public_html/swingsyndicatedance"Both commands seem to indicate a problem with the bootstrap.inc file.
I also encountered this error:
<li><em class="placeholder">Notice</em>: Undefined index: REQUEST_METHOD in <em class="placeholder">_block_render_blocks()</em> (line <em class="placeholder">824</em> of <em class="placeholder">/home1/orianbre/public_html/swingsyndicatedance/modules/block/block.module</em>).</li>
What should I make of all this? Thank you for the help.
Comments
Additional Info
This is Drupal 7 installed at 7.4 and upgraded to 7.7.
Anyone??
Anyone??
A colleague experienced the
A colleague experienced the same thing with Drupal 7 because he had set up the server with the wrong PHP version. But he said he got error messages in the log about this so you may want to check your logs.
I'm currently porting a drupal 5 site to drupal 6 and while they're both on the same server the drupal 6 site takes at least 10000 times longer to save nodes etc. so obviously something is extremely wrong. I have no idea what it may be (because according to another colleague there's nothing wrong with the PHP version on this server), but luckily there are some experienced dudes looking at the problem now. :)
Normal page loads aren't -that- much slower, but doing things like saving nodes, cck-fields, innstalling a module etc. take 4-5 minutes vs a couple of seconds on the drupal 5 site.
Øyvind Strømsvik
Tech lead | Frontkom AS
https://frontkom.com/