当前位置:   article > 正文

ANR traces分析 系统一直出现 waiting for ...日志_waiting channels: pid

waiting channels: pid
Android 系统启动不起原因查找
2015-01-31       0  个评论    来源:oman111的专栏  
收藏     我要投稿
id="iframeu2597680_0" src="http://pos.baidu.com/bccm?sz=650x110&rdid=2597680&dc=2&di=u2597680&dri=0&dis=0&dai=4&ps=329x480&coa=at%3D3%26rsi0%3D650%26rsi1%3D110%26pat%3D6%26tn%3DbaiduCustNativeAD%26rss1%3D%2523F9F9F9%26conBW%3D0%26adp%3D1%26ptt%3D0%26titFF%3D%2525E5%2525BE%2525AE%2525E8%2525BD%2525AF%2525E9%25259B%252585%2525E9%2525BB%252591%26titFS%3D14%26rss2%3D%2523000000%26titSU%3D0%26ptbg%3D90%26piw%3D0%26pih%3D0%26ptp%3D1&dcb=BAIDU_SSP_define&dtm=BAIDU_DUP_SETJSONADSLOT&dvi=0.0&dci=-1&dpt=none&tsr=0&tpr=1464762726823&ti=Android%20%E7%B3%BB%E7%BB%9F%E5%90%AF%E5%8A%A8%E4%B8%8D%E8%B5%B7%E5%8E%9F%E5%9B%A0%E6%9F%A5%E6%89%BE%20-%20Android%E7%A7%BB%E5%8A%A8%E5%BC%80%E5%8F%91%E6%8A%80%E6%9C%AF%E6%96%87%E7%AB%A0_%E6%89%8B%E6%9C%BA%E5%BC%80%E5%8F%91%20-%20%E7%BA%A2%E9%BB%91%E8%81%94%E7%9B%9F&ari=1&dbv=2&drs=1&pcs=1920x911&pss=1920x340&cfv=0&cpl=5&chi=1&cce=true&cec=GBK&tlm=1460995136&ltu=http%3A%2F%2Fwww.2cto.com%2Fkf%2F201501%2F374228.html&ltr=https%3A%2F%2Fwww.baidu.com%2Flink%3Furl%3Dos3jStq4GJIWra4l0hJxBd89JwZK1yHW1rD2sh_dxLmdzl1W6NE-SWiuXSl_S2KSujyH1lp99UERyHUKVXFK6K%26wd%3D%26eqid%3De53819df0062a75100000006574e7fb0&ecd=1&psr=1920x1080&par=1920x1040&pis=-1x-1&ccd=24&cja=false&cmi=7&col=zh-CN&cdo=-1&tcn=1464762727&qn=b0fb864fbe63aa6e&tt=1464762726519.625.717.718" width="650" height="110" align="center,center" vspace="0" hspace="0" marginwidth="0" marginheight="0" scrolling="no" frameborder="0" allowtransparency="true" style="border-width: 0px; border-style: initial; vertical-align: bottom; margin: 0px;">

我们遇到Android系统开机界面(bootanimation)后,系统没法运行起来的问题,

系统一直出现 waiting for ...日志

似乎在等什么服务启动

因此怀疑system server 被block了

调试方法如下:

1. adb shell mkdir /data/anr/

2. adb shell ps | grep system_server


system 1138 234 908376 39440 ffffffff 40061a54 S system_server


3. adb shell kill -3 1138


4. adb shell pull /data/anr/trace.txt


----- pid 1138 at 2014-01-01 08:40:42 -----
Cmd line: system_server


JNI: CheckJNI is off; workarounds are off; pins=1; globals=289


DALVIK THREADS:
(mutexes: tll=0 tsl=0 tscl=0 ghl=0)


"main" prio=5 tid=1 MONITOR
| group="main" sCount=1 dsCount=0 obj=0x4159ee58 self=0x414be920
| sysTid=1138 nice=-2 sched=0/0 cgrp=apps handle=1073963348
| state=S schedstat=( 6367457522 242583118 5270 ) utm=595 stm=41 core=0
at com.android.server.am.ActivityManagerService.registerReceiver(ActivityManagerService.java:~13106)


- waiting to lock <0x41965278> (a com.android.server.am.ActivityManagerService) held by tid=27 (InputDispatcher)


at android.app.ContextImpl.registerReceiverInternal(ContextImpl.java:1458)
at android.app.ContextImpl.registerReceiverAsUser(ContextImpl.java:1433)
at android.content.pm.RegisteredServicesCache.(RegisteredServicesCache.java:134)
at android.content.SyncAdaptersCache.(SyncAdaptersCache.java:43)
at com.android.server.content.SyncManager.(SyncManager.java:399)
at com.android.server.content.ContentService.getSyncManager(ContentService.java:75)
at com.android.server.content.ContentService.notifyChange(ContentService.java:283)
at android.content.ContentResolver.notifyChange(ContentResolver.java:1621)
at com.android.providers.settings.SettingsProvider.sendNotify(SettingsProvider.java:262)
at com.android.providers.settings.SettingsProvider.insertForUser(SettingsProvider.java:941)
at com.android.providers.settings.SettingsProvider.call(SettingsProvider.java:645)
at android.content.ContentProvider$Transport.call(ContentProvider.java:325)
at android.provider.Settings$NameValueCache.putStringForUser(Settings.java:903)
at android.provider.Settings$System.putStringForUser(Settings.java:1169)
at android.provider.Settings$System.putIntForUser(Settings.java:1274)
at android.provider.Settings$System.putInt(Settings.java:1268)

可以清晰的看到调用堆栈,是谁阻塞了system_server 的运行。

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/笔触狂放9/article/detail/203792
推荐阅读
相关标签
  

闽ICP备14008679号