0

I need to record an log even if device restarts cause when I open a specific app my phone restarts so I need to log why.

1

As you can reproduce the crash you can connect your phone via USB to a computer and start

adb logcat -b all

and then start the problematic app on the device.

You will get the logcat output until the device reboots. Hopefully there is an indicator why the crash happens.

Note: this requires enabled adb on the device and adb running on your PC.

There is a second way reading the kernel messages after the reboot happens, but the path (e.g. /proc/last_kmsg) of the saved kernel messages have changed over the time and it is not enabled by default on all devices.

If you are interested in this way see for example this topics:

| improve this answer | |
  • 1
    As a side note: kernel log is not usually helpful when fixing apps related problems. kmsg includes logs only from kernel and some native daemons including init, not Java framework of Android. But pstore can be configured to get logcat if device doesn't boot to adb stage. – Irfan Latif Jan 9 at 18:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.