mysqldumpslow
Do not abstract all numbers to
•
[351],
--debug
-d
Run in debug mode.
•
-g pattern
Consider only queries that match the (grep-style) pattern.
•
-h host_name
Host name of MySQL server for
default is
(match all).
*
•
-i name
Name of server instance (if using
•
-l
Do not subtract lock time from total time.
•
-n N
Abstract numbers with at least
•
-r
Reverse the sort order.
•
-s sort_type
How to sort the output. The value of
• t, at: Sort by query time or average query time
• l, al: Sort by lock time or average lock time
• r, ar: Sort by rows sent or average rows sent
• c: Sort by count
By default,
mysqldumpslow
•
-t N
Display only the first
•
[351],
--verbose
-v
Verbose mode. Print more information about what the program does.
Example of usage:
shell>
mysqldumpslow
Reading mysql slow query log from /usr/local/mysql/data/mysqld51-apple-slow.log
Count: 1
Time=4.32s (4s)
insert into t2 select * from t1
Count: 3
Time=2.53s (7s)
insert into t2 select * from t1 limit N
Count: 3
Time=2.13s (6s)
— Summarize Slow Query Log Files
and strings to 'S'.
N
*-slow.log
mysql.server
digits within names.
N
sort_type
sorts by average query time (equivalent to
queries in the output.
N
Lock=0.00s (0s)
Lock=0.00s (0s)
Lock=0.00s (0s)
351
file name. The value can contain a wildcard. The
startup script).
should be chosen from the following list:
Rows=0.0 (0), root[root]@localhost
Rows=0.0 (0), root[root]@localhost
Rows=0.0 (0), root[root]@localhost
-s
at).
Need help?
Do you have a question about the 5.0 and is the answer not in the manual?
Questions and answers