[rt-users] Severe performance problems suddenly in RT 3.8.2

Dave Holland dh3 at sanger.ac.uk
Wed Feb 18 12:54:41 EST 2009


On Tue, Feb 17, 2009 at 05:52:23PM -0500, Jesse Vincent wrote:
> An excellent question. I have a sneaking suspicion there's some DB
> corruption in there somewhere :/ But maybe it's just a database bug.

After chasing some red herrings we found something "interesting":

mysql> select count(*) from Attachments;
+----------+
| count(*) |
+----------+
|   807113 |  
+----------+
1 row in set (1 min 47.01 sec)

mysql> select count(*) from Attachments ignore index(PRIMARY);
+----------+
| count(*) |
+----------+
|   807113 | 
+----------+
1 row in set (0.66 sec)

So I did a quick "alter table Attachments drop primary key, add primary
key (id);" and now we are seeing much more sensible behaviour:

mysql> select count(*) from Attachments;
+----------+
| count(*) |
+----------+
|   807568 | 
+----------+
1 row in set (0.00 sec)

There is still an occasional hiccup when it goes slower - possibly when
an Attachment has been added - but by and large it's working as expected
now.

Thanks everyone for your help, I've learned rather a lot about MySQL in
the last day or so!

Cheers,
Dave
-- 
** Dave Holland ** Systems Support -- Infrastructure Management **
** 01223 496923 ** The Sanger Institute, Hinxton, Cambridge, UK **
"I've learned so much from my mistakes, I think I'll make some more."


-- 
 The Wellcome Trust Sanger Institute is operated by Genome Research 
 Limited, a charity registered in England with number 1021457 and a 
 company registered in England with number 2742969, whose registered 
 office is 215 Euston Road, London, NW1 2BE. 



More information about the rt-users mailing list