pt-query-digest Reading from STDIN …問題

今天優化Box Anemometer慢日誌導入的腳本,在調試時pt-query-digest一直卡在Reading from STDIN ...不動,而別一臺機器順利執行成功。 查看幫助

pt-query-digest --help
pt-query-digest analyzes MySQL queries from slow, general, and binary log files.
It can also analyze queries from C<SHOW PROCESSLIST> and MySQL protocol data
from tcpdump. By default, queries are grouped by fingerprint and reported in
descending order of query time (i.e. the slowest queries first). If no C<FILES>
are given, the tool reads C<STDIN>. The optional C<DSN> is used for certain
options like L<"--since"> and L<"--until">. For more details, please use the
--help option, or try 'perldoc /usr/local/percona-toolkit/bin/pt-query-digest'
for complete documentation.

意思是如果沒有給定FILE則等待輸入,ls命令驗證是文件不存在,原因是跟另一臺機器的文件名不一樣,拷貝命令過來直接執行肯定不行啦,把文件名改爲本機的慢日誌名稱即可執行完成


發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章