Help information for "LOGCAT" adb logcat-h

Source: Internet
Author: User
Tags tag name

Help information for ADB logcat-h

usage: logcat [options] [filterspecs]options include:  -s               Set default filter to  silent.                   Like specifying filterspec  ' *:s '   -f <filename>   log  to file. Default to stdout  -r [<kbytes>]    rotate log every kbytes.  (16 if unspecified).  requires -f  - n <count>      sets max number of rotated  logs to <count>, default 4  -v <format>      sets the log print format, where <format> is one of:     &Nbsp;             brief process tag  thread raw time threadtime long  -c               clear  (flush)  the entire log and  exit  -d               dump the log and then exit  (Don ' T block)   -t <count>       print only the most recent <count>  lines  (implies -d)   -t  ' <time> '      print most  recent lines since specified time  (implies -d)   -T < Count>      print only the most recent <count>  lines  (does not imply -d)   -T  ' <time> '      print most recent  lines since specified time  (not imply -d)                    count is pure  numerical, time is  ' Mm-dd hh:mm:ss.mmm '   -g               get the size of the log ' s ring  buffer and exit  -b <buffer>     Request  alternate ring buffer,  ' main ',  ' System ',  ' radio ',                    ' events ',  ' Crash '  or  ' All ' . multiple -b parameters are              &nBsp;    allowed and results are interleaved. the default  is                   -b main -b system -b crash.  -B               output the log in binary.  -s               output statistics.   -G <size>       set size of log  ring buffer, may suffix with k or m.  -p               print prune white and ~black  list. Service is specified as                   uid, uid/pid or /pid. weighed for quicker  pruning if prefix                   with ~, otherwise weighed for longevity if  unadorned. all                   other pruning activity is oldest first. special case  ~!                   represents an automatic quicker pruning for the noisiest                   uid as  determined by the current statistics.  -P  ' <list>&nbsp, ... '  set prune white and ~black list, using same format as                   printed above. Must be  quoted.filterspecs are a series of   <tag>[:p riority]where < tag> is a log component tag  (Or * for all)  and  priority is:  v    verbose  d    debug   I    Info  W    Warn  E     Error  F    Fatal  S    Silent  (supress  all output) ' * '  means  ' *:d '  and <tag> by itself means  <tag>:vif not specified on the commandline, filterspec is set  from android_Log_tags. if no filterspec is found, filter defaults to  ' *:I ' If not  Specified with -v, format is set from android_printf_logor defaults  to  "Brief"
Logs are used to display log streams on the command line: Adb logcat Filter by tag name Adb logcat -s tag_nameadb logcat -s tag_name _1 tag_name_2# exampleadb logcat -s testadb logcat -s test  MyApp Filter By priority displays the log:adb logcat  "*:P riority" # exampleadb logcat  "*:w" for the specified alarm priority level and above The priority setting is the following:v:verbose  (lowest priority) d:debugi:infow:warninge:errorf:fatals:silent  (the highest priority,  does not print any information at this level) Filter adb logcat -s tag_name:priority  adb logcat -s tag_name_1 by label signature and priority: Priority tag_name_2:priority '  # example  adb logcat -s TEST:  W using grep filtering In addition, in a system that supports grep, the LOGCAT output can be piped to grep:adb logcat | grep  "Search_term" adb  logcat | grep  "search_term_1\| Search_term_2 "# exampleadb logcat | grep " Exception "Adb logcat | grep   "exception\| Error "Clear the Logcat buffer using this command to clear the buffer and clear the old log data: Adb logcat -c


Help information for "LOGCAT" adb logcat-h

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.