I have been having a few problems with one of my clients site. Its a big site, theres a few thousand nodes, 10k users, and it holds large images galleries with 100+ images that are 500kb each.
At its slowest, the average page load is 45 seconds!! And the worst i when you are logged in.
After enabling devel query logs, this one stands out as the worst...
3923.69 ms 1 node_tag_new P A INSERT INTO history (uid, nid, timestamp) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2)
Thats the first page load, the second is much much worse....
65594.921 ms node_tag_new P A UPDATE history SET timestamp=:db_update_placeholder_0 WHERE ( (uid = :db_condition_placeholder_0) AND (nid = :db_condition_placeholder_1) )
What is the history table? Any idea why it is taking so long to run the query?