logcat命令使用方法和查看android系统日志缓冲区内容的方法

2019-12-10 20:09:33王振洲

                  raw 
                  time 
                  threadtime 
                  long

  -c              clear (flush) the entire log and exit
                  清除所有 log 并退出

  -d              dump the log and then exit (don't block)
                  得到所有log并退出且不阻塞

  -t <count>      print only the most recent <count> lines (implies -d)
                  仅打印最近的由参数 count 指出的行数(必然包含 -d)

  -g              get the size of the log's ring buffer and exit
                  得到环形缓冲区的大小并退出

  -b <buffer>     Request alternate ring buffer, 'main', 'system', 'radio' or 'events'.
                  Multiple -b parameters are allowed and the results are interleaved. 
                  The default is -b main -b system.
                  请求供替换的环形缓冲区,如:main,system,radio,events。
                  多个 -b 参数是被允许,并且结果是交错输出的。
                  -b main -b system 是默认的。

  -B              output the log in binary
                  输出 log 到二进制文件中。

filterspecs are a series of <tag>[:priority]
过滤说明是一系列 <tag>[:priority]