StatsDawg

To See What Your Server Is Barking At

Home : Help : About

MySQL General Performance Statistics

This section shows various statistics in regards to the general performance of MySQL. This includes the percentages of selects, inserts, updates, and deletes. This information can also be obtained from the MySQL Query Distribution Graph, although the numbers here represent the percentage of queries since the last restart, meaning that it is best to look at both this and the graph.

This section also shows information about the number of current and max connections, as well as the number of threads cached and running. This helps paint of picture of how efficiently threads are being created and used. For instance, if there is a high number of current connections, but a low number of threads running, it may indicate that you have are large amount of sleeping threads. This can indicate situations where a MySQL connection was left open without being properly closed and can sometimes caused problems when the number of sleeping connections approaches that maximum number of connections allowed (which is configurable in MySQL using the max_connections variable).

General Performance Stats

Current Connections:7
Max Used Connections:25
Threads Cached:10
Threads Running:2
Uptime (In Seconds):250075
Select Percentage:98.48%
Insert Percentage:0.39%
Update Percentage:0.8%
Delete Percentage:0.33%

Non-Indexed Joins:0
Sort Merge Passes:0
Slow Queries:0
Open Tables:332
Temp Tables (Disk):964
Delayed Table Locks:0

The section on the bottom-left deals with slow queries and table scans under certain situations, such as performing a table-scan for a join or for a table-sort. Ideally, all of these values should be relatively low since table scans are generally expensive and slow queries indicate, of course, that a query reached the long query time threashold and was marked as slow (this is configurable by setting the long_query_time variable in MySQL). If these are values are unusually high, it may indicate that you could benefit from indexing tables, or even rewritting queries to make things more efficient.

Finally, the section on the bottom-right deals specifically with tables. In particular, the number of currently open tables, the number of disk based temp tables, and the number of non-immediate table-locks. The number of open tables is what it implies; these are tables which MySQL currently has open (and has open file handles for). If this number if close to the max, you may want to increase the table_cache variable in MySQL, although the performance benefit is generally modest. The disk based temp tables, by contrast, are the number of temporary tables that either could not fit in RAM or required a disk based temporary table. As disk tables are generally expensive, this value should usually be small. You can adjust the amount of RAM available for temp tables by setting the tmp_table_size and max_heap_table_size variables in MySQL.


Return to Table of Contents