grep:Binary file (standard input) matches

grep "key" xxx.log时输出

Binary file xxx.log matches

百度了一下:grep觉得这是二进制文件。解决方式:grep -a。

grep -a "key" xxx.log

原文地址:https://www.cnblogs.com/zfyouxi/p/5283691.html