Sunday, February 16, 2014

How to: Generate a kernel log after random reboot

Once in a while, a software bug in the kernel will cause a random reboot, so in order to help kernel developers to fix and troubleshoot the reboots, a kernel log need to be submitted to the developer for further analysis and hopefully lead to a bug fix.

Most Android kernels have "RAM Consoles" to save the necessary kernel logs immediately after reboot in the RAM.  The users can then retrieve this RAM log on a subsequent reboot to submit to kernel developers. Here is a quick tour on how to do that.


[ Using ADB ]
  1. adb shell
  2. su
  3. cat /proc/last_kmsg > /sdcard/last_kmsg.txt
  4. exit
  5. exit
  6. adb pull /sdcard/last_kmsg.txt
File last_kmsg.txt will be located in the same location as adb.exe executable.


[ Using android terminal app ]
  1. su
  2. cat /proc/last_kmsg > /sdcard/last_kmsg.txt
  3. exit
  4. exit
  5. adb pull /sdcard/last_kmsg.txt
File last_kmsg.txt will be located on your SD-card.


[ Using Root Explorer / ES Explorer with Root ]
  1. go to /proc folder
  2. copy last_kmsg to /sdcard/
  3. rename last_kmsg to last_kmsg.txt
File last_kmsg.txt will be located on your SD-card.

The best method to share the last_kmsg.txt content is to upload it to pastebin.com and send a link to the developer.

Source: faux123 (Google +)

Have any questions or comments? Feel free to share! Also, if you like this article, please use media sharing buttons (Twitter, G+, Facebook) below this post!

17 comments:

  1. This is very interesting, You are a very skilled blogger. I have joined your rss feed and look forward to seeking more of your great post. Also, I have shared your site in my social networks! Unique Dofollow Backlinks

    ReplyDelete
  2. Excellent work done by you once again here and this is just the reason why I’ve always liked your work with amazing writing skills and you display them in every article. Keep it going! 토토사이트

    ReplyDelete
  3. Its a wonderful post and very helpful, thanks for all this information. 바카라사이트닷컴

    ReplyDelete
  4. You made a blog with great information in an effective way. Thank you so much for sharing. 파워볼사이트닷컴

    ReplyDelete
  5. The data you have posted is exceptionally helpful. The destinations you have alluded was great. A debt of gratitude is in order for sharing…

    토토사이트
    토토
    파워볼
    먹튀검증

    ReplyDelete
  6. It’s awesome that you want to share those tips with us. It is a very useful post Keep it up and thanks to the writer.

    토토사이트
    토토
    파워볼
    먹튀검증

    ReplyDelete
  7. Thanks for sharing a great article. You are providing wonderful information, it is very useful to us. Keep posting like this informative articles. Thank you. 토토


    ReplyDelete
  8. Appreciation to my father who stated to me on the topic of this weblog, this webpage is really amazing.

    경마

    ReplyDelete
  9. I’m truly enjoying the design and layout of your site. It’s a very easy on the eyes which makes it much more enjoyable for me to come here and visit more often. 카지노

    ReplyDelete
  10. THIS POST IS VERY USEFUL. THANK YOU FOR THIS USEFULL INFORMATION.~

    ReplyDelete
  11. I NEVER STOP MYSELF TO SAY SOMETHING ABOUT IT. YOU’RE DOING A GREAT JOB, KEEP IT UP!*****

    ReplyDelete
  12. Big thumbs up for making such wonderful blog page!

    ReplyDelete
  13. Good article. I’m going through many of these issues as well..

    ReplyDelete
  14. Appreciate your sharing this greatest doc.

    ReplyDelete
  15. Keep up the good works guys I’ve included you guys to blogroll.

    ReplyDelete
  16. Thanks for sharing this with so much of detailed information.

    ReplyDelete
  17. Keep doing this in future. I will support you.

    ReplyDelete