LogCat: Unable to open log device

拟墨画扇 提交于 2019-12-11 00:23:17

问题


My Phone: Samsung Galaxy Note N7000 Kernel: HyDraCore_v6.2_B3_R3P0 Build: MIUI-2.10.19 RocketMIUI v8

I read many threads about that but nothing solved my problem... When I connect my phone to my computer and run the project wirh "Run As -> Android Application" the program starts on my phone but the logcat is empty in eclipse :-/ In logcat I only receive this one message:

Unable to open log device '/dev/log/main': No such file or directory

What do I have to do to get it worked??


回答1:


I'm using Slim Rom (4.2.2, build 5) mod and they have disabled logging by default. What you have to to is to go to /res/script directory on your device and find relevant script for enablig log. In my case it's S30enable_logger. For your custom rom the scripts can have different naming convention (or directory) - consider checking it with your custom rom id.

So, given that you are connected to your device via adb type in your pc terminal :

adb shell 
cd /res/scripts
./S30enable_logger

Then just reboot your device and log should work finally.



来源:https://stackoverflow.com/questions/13176437/logcat-unable-to-open-log-device

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!