Android Phone log capture

Source: Internet
Author: User
Tags memory usage cpu usage

Android app Development is complete, sometimes is not the log to save the remote or local, when there is a problem, it is not easy to locate.

Then non-developers can use Android-sdk-windows's adb shell to complete the log view

Output System state information to F:\test\dumpstate.txt, because root permission is required, so no root of the phone output is empty adb shell dumptate >f:\test\dumpstate.txt// Output the state of the past system, log, the general operation of the process when the log is not captured in the event of a problem with this command to view the ADB shell bugreport >f:\test\bugreport.txt//output kernel information adb shell dmesg/ /output Current buffer log and save adb shell Logcat    >f:\test\bugreport.txt//output memory information adb shell Dumpsys meminfo//Output Current CPU usage information adb shell Dumpsys cpuinfo//Output Current Activity usage information adb shell Dumpsys activity//equivalent to filtering, only find activity usage information named "MF" adb shell Dumpsys Activity | Find "MF"//Get the key information, the phone does not have key information, you will be prompted each device ID represents the device information, the key process will be in real-time refresh adb shell getevent//get System Properties adb shell getprop// View PM Help information adb shell pm//View the list of installed packages in the phone adb shell pm List packages//View current phone process information adb shell ps//get CPU usage, view only once, do not refresh adb shell top in real time- n 1//get top Ten CPU usage, view only once, do not refresh adb shell top-   n 1-m 10//query Each memory consumption situation adb shell procrank//detailed query memory usage of a package adb shell Dumpsys Meminfo PackageName

Android Phone log capture

Related Article

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.