暂无图片
明明慢查询中有记录,digest指定时间段后却不打印结果?
我来答
分享
暂无图片 匿名用户
明明慢查询中有记录,digest指定时间段后却不打印结果?


pt-query-digest --since "2024-09-13 09:00:00" --until "2024-09-13 11:00:00" /data/mysql_8/data/test_dan-slow.log

# No events processed.

[root@test_dan data]# tail -30 test_dan-slow.log
select * from t1 limit 3;
# Time: 2024-09-10T16:23:22.038451+08:00
# User@Host: root[root] @ localhost [] Id: 8
# Query_time: 0.130521 Lock_time: 0.096975 Rows_sent: 2 Rows_examined: 5
SET timestamp=1725956601;
(select 1000 as f) union (select id from t1 order by id desc limit 2);
/usr/local/mysql8/bin/mysqld, Version: 8.0.18 (MySQL Community Server - GPL). started with:
Tcp port: 3338 Unix socket: /tmp/mysql_3338.sock
Time Id Command Argument
# Time: 2024-09-13T09:38:11.289432+08:00
# User@Host: root[root] @ localhost [] Id: 8
# Query_time: 0.605194 Lock_time: 0.000000 Rows_sent: 1 Rows_examined: 1
SET timestamp=1726191490;
select @@version_comment limit 1;
# Time: 2024-09-13T10:01:06.965911+08:00
# User@Host: root[root] @ localhost [] Id: 8
# Query_time: 0.772177 Lock_time: 0.225260 Rows_sent: 1 Rows_examined: 594
SET timestamp=1726192866;
show variables like '%datadir%';
# Time: 2024-09-13T10:07:22.378684+08:00
# User@Host: root[root] @ localhost [] Id: 8
# Query_time: 0.117331 Lock_time: 0.061207 Rows_sent: 4 Rows_examined: 4
use dba;
SET timestamp=1726193242;
select * from tab2;
# Time: 2024-09-13T10:08:19.927779+08:00
# User@Host: root[root] @ localhost [] Id: 8
# Query_time: 20.010737 Lock_time: 0.000119 Rows_sent: 4 Rows_examined: 4
SET timestamp=1726193279;
select *,sleep(5) from tab2;

我来答
添加附件
收藏
分享
问题补充
1条回答
默认
最新
everything

排查过时区问题么

暂无图片 评论
暂无图片 有用 1
手机用户9375
2024-09-14
time_zone | SYSTEM |
回答交流
提交
问题信息
请登录之后查看
邀请回答
暂无人订阅该标签,敬请期待~~
暂无图片墨值悬赏