[mythtv-users] Very slow mythfrontend, mysql at 100%

Michael T. Dean mtdean at thirdcontact.com
Fri Nov 20 15:43:38 UTC 2009


On 11/20/2009 10:21 AM, Dan Wilga wrote:
> You've got a few NULLs in the "key" column which suggest possible 
> inefficiencies due to missing indices. For starters, it definitely 
> looks like you are missing indices on the oldrecorded (aliased as 
> oldrecstatus) table. Here's what the schema says there should be:
>
> ALTER TABLE oldrecorded ADD  PRIMARY KEY  (station,starttime,title);
> ALTER TABLE oldrecorded ADD  KEY endtime (endtime);
> ALTER TABLE oldrecorded ADD  KEY title (title);
> ALTER TABLE oldrecorded ADD  KEY seriesid (seriesid);
> ALTER TABLE oldrecorded ADD  KEY programid (programid);
> ALTER TABLE oldrecorded ADD  KEY recordid (recordid);
> ALTER TABLE oldrecorded ADD  KEY recstatus 
> (recstatus,programid,seriesid);
> ALTER TABLE oldrecorded ADD  KEY recstatus_2 (recstatus,title,subtitle); 

He posted his indices to another message ( 
http://www.gossamer-threads.com/lists/mythtv/users/409074#409074 ).  
None are missing.

And please, do not edit the database schema.

The best approach, now, would be to do the backup/restore I outlined in 
another message. ( 
http://mythtv.org/pipermail/mythtv-users/2009-November/271541.html )

Mike


More information about the mythtv-users mailing list