修改配置文件/etc/my.cnf 新增一行:query_cache_type=1 重启mysql
先开启 show variables like '%profiling%';
show variables like '%profiling%';
set profiling=1;
select * from xxx ;
show profiles; #显示最近的几次查询
show profile cpu,block io for query 编号 #查看程序的执行步骤
京公网安备 11010502049817号