patternsqlMinor
Table cache hit rate is 0% - is that a huge concern?
Viewed 0 times
hitrateconcernhugecachethattable
Problem
Hi all of a sudden my server has slowed to a crawl, queries that were 0.10 of a second consistently now taking 20 seconds. somewhat randomly, sometimes it snaps right back. so I have a really sudden and harsh performance problem.
I ran mysqltuner.pl and it reported one thing that might be a problem :
I am just starting to delve into this performance problem, but does anyone know if this a big immediate red flag?
I can do some DD but am pressed right now. any help much appreciated.
Don
I ran mysqltuner.pl and it reported one thing that might be a problem :
[!!] Table cache hit rate: 0% (400 open / 1M opened)I am just starting to delve into this performance problem, but does anyone know if this a big immediate red flag?
I can do some DD but am pressed right now. any help much appreciated.
Don
Solution
The query cache was only hit 400 out of 1,000,000 times.
That is a query cache hitrate of 0.04 %
This indicates that 99.96% of your queries are unique and are not reusable. That's not unusual if your are storing session data, doing blogging, audit trails, or just plain logging of events.
While you could setup slow query logging, there is a better approach to checking on SQL performance. I recommend using pt-query-digest with --processlist option or --tcpdump option
This will allow you to catch bad queries in the act of being bad.
That is a query cache hitrate of 0.04 %
This indicates that 99.96% of your queries are unique and are not reusable. That's not unusual if your are storing session data, doing blogging, audit trails, or just plain logging of events.
While you could setup slow query logging, there is a better approach to checking on SQL performance. I recommend using pt-query-digest with --processlist option or --tcpdump option
This will allow you to catch bad queries in the act of being bad.
Context
StackExchange Database Administrators Q#20298, answer score: 2
Revisions (0)
No revisions yet.