之前只知道set profiling=1,然后执行语句,然后show profile for query xx的调优方法。
今天发现show profile也有几个参数来显示更详细的语句执行情况的记录。
SHOW PROFILE [type
[, type
] ... ]
[FOR QUERY n
]
[LIMIT row_count
[OFFSET offset
]]
type:
- ALL - displays all information
- BLOCK IO - displays counts for block input and output operations
- CONTEXT SWITCHES - displays counts for voluntary and involuntary context switches
- IPC - displays counts for messages sent and received
- MEMORY - is not currently implemented
- PAGE FAULTS - displays counts for major and minor page faults
- SOURCE
- displays the names of functions from the source code, together with
the name and line number of the file in which the function occurs
- SWAPS - displays swap counts
阅读(3117) | 评论(0) | 转发(0) |