APK无法在Android 4.0模拟器上安装

时间:2011-10-28 08:57:03

标签: android-emulator

在所有以前的SDK-s apk上工作正常。试图在4.0上测试。下载了eclipse的所有最新更新。我得到了什么

...

[2011-10-28 11:39:34 - breath-trainer] Android Launch!
[2011-10-28 11:39:34 - breath-trainer] adb is running normally.
[2011-10-28 11:39:34 - breath-trainer] Performing com.breath.ui.activity.BreathTrainerActivity activity launch
[2011-10-28 11:39:37 - breath-trainer] Launching a new emulator with Virtual Device '4.0_api_14_SUKA'
[2011-10-28 11:39:38 - breath-trainer] New emulator found: emulator-5554
[2011-10-28 11:39:38 - breath-trainer] Waiting for HOME ('android.process.acore') to be launched...
[2011-10-28 11:40:30 - breath-trainer] HOME is up on device 'emulator-5554'
[2011-10-28 11:40:30 - breath-trainer] Uploading breath-trainer.apk onto device 'emulator-5554'
[2011-10-28 11:40:31 - breath-trainer] Installing breath-trainer.apk...
[2011-10-28 11:40:56 - breath-trainer] Success!
[2011-10-28 11:40:56 - breath-trainer] Failed to install breath-trainer.apk on device 'emulator-5554': device not found
[2011-10-28 11:40:56 - breath-trainer] com.android.ddmlib.InstallException: device not found
[2011-10-28 11:40:56 - breath-trainer] Launch canceled!

同样在LogCat中,有很多关于StrictMode策略违规的例外和最小的例外:

10-28 11:40:51.711: A/NetworkStats(74): problem reading network stats
10-28 11:40:51.711: A/NetworkStats(74): java.lang.IllegalStateException: problem parsing line: null
10-28 11:40:51.711: A/NetworkStats(74):     at com.android.internal.net.NetworkStatsFactory.readNetworkStatsDetail(NetworkStatsFactory.java:313)
10-28 11:40:51.711: A/NetworkStats(74):     at com.android.server.NetworkManagementService.getNetworkStatsUidDetail(NetworkManagementService.java:1223)
10-28 11:40:51.711: A/NetworkStats(74):     at com.android.server.net.NetworkStatsService.performPollLocked(NetworkStatsService.java:810)
10-28 11:40:51.711: A/NetworkStats(74):     at com.android.server.net.NetworkStatsService.updateIfacesLocked(NetworkStatsService.java:721)
10-28 11:40:51.711: A/NetworkStats(74):     at com.android.server.net.NetworkStatsService.updateIfaces(NetworkStatsService.java:699)
10-28 11:40:51.711: A/NetworkStats(74):     at com.android.server.net.NetworkStatsService.access$000(NetworkStatsService.java:128)
10-28 11:40:51.711: A/NetworkStats(74):     at com.android.server.net.NetworkStatsService$8.handleMessage(NetworkStatsService.java:1546)
10-28 11:40:51.711: A/NetworkStats(74):     at android.os.Handler.dispatchMessage(Handler.java:95)
10-28 11:40:51.711: A/NetworkStats(74):     at android.os.Looper.loop(Looper.java:137)
10-28 11:40:51.711: A/NetworkStats(74):     at android.os.HandlerThread.run(HandlerThread.java:60)
10-28 11:40:51.711: A/NetworkStats(74): Caused by: java.io.FileNotFoundException: /proc/net/xt_qtaguid/stats: open failed: ENOENT (No such file or directory)
10-28 11:40:51.711: A/NetworkStats(74):     at libcore.io.IoBridge.open(IoBridge.java:406)
10-28 11:40:51.711: A/NetworkStats(74):     at java.io.FileInputStream.<init>(FileInputStream.java:78)
10-28 11:40:51.711: A/NetworkStats(74):     at java.io.FileReader.<init>(FileReader.java:42)
10-28 11:40:51.711: A/NetworkStats(74):     at com.android.internal.net.NetworkStatsFactory.readNetworkStatsDetail(NetworkStatsFactory.java:272)
10-28 11:40:51.711: A/NetworkStats(74):     ... 9 more
10-28 11:40:51.711: A/NetworkStats(74): Caused by: libcore.io.ErrnoException: open failed: ENOENT (No such file or directory)
10-28 11:40:51.711: A/NetworkStats(74):     at libcore.io.Posix.open(Native Method)
10-28 11:40:51.711: A/NetworkStats(74):     at libcore.io.BlockGuardOs.open(BlockGuardOs.java:98)
10-28 11:40:51.711: A/NetworkStats(74):     at libcore.io.IoBridge.open(IoBridge.java:390)
10-28 11:40:51.711: A/NetworkStats(74):     ... 12 more

一些想法?

3 个答案:

答案 0 :(得分:2)

'emulator-5554':找不到设备

虚拟设备'4.0_api_14_SUKA'

2理论:

1.-模拟器是api 14(Android 4.0),模拟器空间不足: 试试这个 - &gt; Android 4.0 emulator - out of space error

2.-有时Eclipse和模拟器之间的连接丢失了。关闭模拟器并重新打开它。

答案 1 :(得分:2)

我有这个问题。我无法正确解释它为什么会发生,但我可以告诉你我是如何解决它的。当我收到此消息时,ICS仿真器仍然出现。我的应用程序已安装,可以通过转到应用程序并选择它来启动。对我来说更大的问题是logcat不再有效。为了让它再次运行正在运行的模拟器,我从命令行执行以下操作: (假设您的环境变量已设置) 1)输入“adb” 2)输入“adb kill-server” 3)输入“adb start-server” 4)重新启动应用程序并定位正在运行的模拟器

我希望这对你有用,就像它对我一样。如果有人能够正确地解释这个问题,我会喜欢它。从我所做的研究来看,它看起来与严格模式或某种超时有关。其他人建议我在eclipse中更新adb的超时设置。这对我不起作用,但它可能对其他人有所帮助:Eclipse&gt;偏好&gt; Android&gt; DDMS - 然后将ADB连接超时设置为高于系统启动ICS所需的时间。

答案 2 :(得分:0)

这不是主要问题,我在我的设备上运行它我得到了同样的错误,但ICS运行:P