Tuesday, November 29

Geek

The Grasshopper Learns Another Lesson

After loading a fresh copy of the database, you must analyse the tables before MySQL will do anything remotely sensible with the indexes.

If you fail to do this... DOH!

(Visualise that "DOH!" in 40-foot-high flashing red neon, with searchlights and helicopters flying overhead and police cars and fire engines and so on and so forth.)

Posted by: Pixy Misa at 03:08 AM | Comments (8) | Add Comment | Trackbacks (Suck)
Post contains 66 words, total size 1 kb.

1 Consider it so visualised

Posted by: Rob at Tuesday, November 29 2005 05:34 AM (9UJHr)

2 We were having a real issue with the performance of the MT trackback script - it was chewing up 200MB of memory at a time and taking several seconds to run. Not when someone sent us a trackback, but when someone looked up the trackbacks for a particular post. I was wondering how MT could possibly be screwed up so badly, even if we are stuck on an old version. Turns out that it wasn't MT at all, but MySQL. When we moved servers, it lost all its statistics on the indexes, so it stopped using them! (Insert as many exclamation marks here as you see fit. I think that three or four dozen should do.) I ran a table analysis, and the problem simply went away. Of course, I didn't work that out directly. It was only when my standard index page in Minx went from taking 0.01 seconds to 3.5 seconds that I really started to look at the database. Now the only really poopy thing left with MT is the search script, which I may be forced to drag out behind the barn and shoot.

Posted by: Pixy Misa at Tuesday, November 29 2005 06:21 AM (3FPsg)

3 Oh yeah. I realised that this was the problem with the trackback script just as I got to that point in the post. Hence the neon lights, fire engines, etc.

Posted by: Pixy Misa at Tuesday, November 29 2005 06:22 AM (3FPsg)

4 When you shoot it, make sure there are no witnesses.... ;)

Posted by: Susie at Tuesday, November 29 2005 08:13 AM (a0oF7)

5 I can visualize it, even if I don't understand it.

Posted by: RP at Tuesday, November 29 2005 05:29 PM (LlPKh)

6 That's why you should run MT on flatfile databases. No pesky index to think of!

Posted by: Jojo at Tuesday, November 29 2005 09:30 PM (vlKqG)

7 I'm a duck. I'm supposed to understand this? As previously mentioned: I like pie.

Posted by: Wonderduck at Tuesday, November 29 2005 09:49 PM (mAAjO)

8 I understand pie. Mmm-mmm, pie!

Posted by: Wonderduck at Tuesday, November 29 2005 09:50 PM (mAAjO)

Hide Comments | Add Comment

Comments are disabled. Post is locked.
48kb generated in CPU 0.0127, elapsed 0.1011 seconds.
56 queries taking 0.0935 seconds, 334 records returned.
Powered by Minx 1.1.6c-pink.