首页 > 代码库 > grep:Binary file (standard input) matches

grep:Binary file (standard input) matches

grep "key" xxx.log时输出

Binary file xxx.log matches

百度了一下:grep认为这是二进制文件,解决方案:grep -a。

grep -a "key" xxx.log

grep:Binary file (standard input) matches