The XDAndroid Project is no longer active.
This site provides archived information from while the project was under development. Some links may no longer function.

Difference between revisions of "Logs"

From The XDAndroid Project
Jump to navigation Jump to search
[checked revision][checked revision]
Line 5: Line 5:
 
<code>adb shell dmesg > dmesg.txt</code> will dump a dmesg log (kernel traces) to a file &mdash; dmesg.txt &mdash; on your computer.  Note this command will drop dmesg.txt where ever you are currently running the command from &mdash; watch the path you are at!
 
<code>adb shell dmesg > dmesg.txt</code> will dump a dmesg log (kernel traces) to a file &mdash; dmesg.txt &mdash; on your computer.  Note this command will drop dmesg.txt where ever you are currently running the command from &mdash; watch the path you are at!
  
<code>adb logcat -v time > logcat.txt</code> will dump a logcat file (userland traces, with timestamps).
+
<code>adb logcat -v time -d > logcat.txt</code> will dump a logcat file (userland traces, with timestamps).
  
<code>adb logcat -b radio -v time > logcat_radio.txt</code> will dump a file radio-specific logs. ([[Wikipedia:Radio Interface Layer|RIL]]).
+
<code>adb logcat -b radio -v time -d > logcat_radio.txt</code> will dump a file radio-specific logs. ([[Wikipedia:Radio Interface Layer|RIL]])
  
You can also run these on the phone directly. Note: dmesg runs and ends while the two logcat commands run continuously.  You will have to break them (CTRL-C) to get the log to quit and give you back a prompt.
+
You can also run these on the phone directly.  
 +
 
 +
Note: if you want to run the logs continuously, for both logcat commands remove the -d.  You will have to break them (CTRL-C) to get the log to quit and give you back a prompt.
 +
 
 +
For a continuous dmesg, you have to use a different command - <code>cat /proc/kmsg > dmesg.txt</code> - again, break with (CTRL-C).

Revision as of 02:27, 18 June 2011

rpierce99 actually made a great app called GetLogs. Check it out, makes taking logs much, much easier! (Does things like auto-masking, direct posting to pastebin, etc.)

If you want to pull logs manually, the most popular kind are dmesg, logcat and logcat -b radio.

adb shell dmesg > dmesg.txt will dump a dmesg log (kernel traces) to a file — dmesg.txt — on your computer. Note this command will drop dmesg.txt where ever you are currently running the command from — watch the path you are at!

adb logcat -v time -d > logcat.txt will dump a logcat file (userland traces, with timestamps).

adb logcat -b radio -v time -d > logcat_radio.txt will dump a file radio-specific logs. (RIL)

You can also run these on the phone directly.

Note: if you want to run the logs continuously, for both logcat commands remove the -d. You will have to break them (CTRL-C) to get the log to quit and give you back a prompt.

For a continuous dmesg, you have to use a different command - cat /proc/kmsg > dmesg.txt - again, break with (CTRL-C).