[mythtv-users] Slow MySQL query after delete

jack snodgrass mrlinuxgroups at gmail.com
Tue Sep 4 00:57:21 UTC 2007

On 9/3/07, crs23 <pvr at groundhog.pair.com> wrote:
> jack snodgrass-2 wrote:
> >
> > On 9/2/07, crs23 <pvr at groundhog.pair.com> wrote:
> >>
> >
> > .. I'm not sure I see the issues your having... you say that the query
> > takes 35 - 40 seconds, but the one you show says:
> >
> > "10 rows in set (0.02 sec)"
> >
> > I can past in that long-ass query you posted and it takes 68 rows in set
> > (0.02 sec) for me too.....
> >
> > where / when / how exactly are you seeing thins query take 30+ seconds?
> >
> The query I gave was an 'EXPLAIN SELECT' not the actual 'SELECT', which is
> why it was so fast -- it wasn't actually doing the select, just showing how
> it would.  The actual SELECT occurs shortly after deleting a program or two.
> I turned on logging of slow queries in mysql and pulled the query from
> there.  I don't know where or why the backend performs the query though it
> shouldn't be hard to find.
> So your query took 0.02 seconds and it was the actual query, not the
> 'EXPLAIN' query?

I cut / pasted the SELECT statement you sent... it did not have an
'explain' in there
so it ran the standard select and returned 68 records.

Have you run the optimize_mythdb.pl to see if that speeds anything up?

Can you just run that long-ass select query using mysql or phpMyAdmin
and see if it ALWAYS takes a long time or if it's usually quick and slow
every once in a while. If it's always slow... that's one thing... if
it's randomly
slow... that's something else.


More information about the mythtv-users mailing list