gpt4 book ai didi

android - 无法从 Android 模拟器插件设置分区大小

转载 作者:行者123 更新时间:2023-11-29 01:35:09 25 4
gpt4 key购买 nike

我正在尝试将 HOSTS 文件复制到使用 jenkins 中的 android-emulator-plugin 创建的 avd。我已将分区大小指定为 128,这在从命令行运行时工作得很好,但是当我将主机文件复制到/system/etc/hosts 时,它在推送过程中总是返回内存不足错误。构建的输出如下:

/Users/Shared/Jenkins/Home/tools/android-sdk/tools/emulator -no-boot-anim -ports 5644,5645 -prop persist.sys.language=en -prop persist.sys.country=US -avd hudson_en-US_240_WXGA720_android-17_x86_blackwidow_integration_test -no-snapshot-load -no-snapshot-save -no-window -partition-size 128
_RegisterApplication(), FAILED TO establish the default connection to the WindowServer, _CGSDefaultConnection() is NULL.
emulator: WARNING: 1: key name doesn't start with valid character. line ignored
Failed to create Context 0x3005
emulator: WARNING: Could not initialize OpenglES emulation, using software renderer.
HAX is working and emulator runs in fast virt mode
$ /Users/Shared/Jenkins/Home/tools/android-sdk/platform-tools/adb connect emulator-5644
[android] Waiting for emulator to finish booting...
$ /Users/Shared/Jenkins/Home/tools/android-sdk/platform-tools/adb -s emulator-5644 shell getprop dev.bootcomplete
error: device offline
$ /Users/Shared/Jenkins/Home/tools/android-sdk/platform-tools/adb -s emulator-5644 shell getprop dev.bootcomplete
error: device offline
$ /Users/Shared/Jenkins/Home/tools/android-sdk/platform-tools/adb -s emulator-5644 shell getprop dev.bootcomplete
$ /Users/Shared/Jenkins/Home/tools/android-sdk/platform-tools/adb -s emulator-5644 logcat -v time
[android] Emulator is ready for use (took 35 seconds)
[android] Searching for Android projects...
[android] Project file 'smartfusion-android/project.properties' requires platform 'android-21'
[android] Ensuring platform(s) are installed: [android-21]
$ /Users/Shared/Jenkins/Home/tools/android-sdk/tools/android list target
[fusion-android] $ /bin/sh -xe /Users/Shared/Jenkins/tmp/hudson4186611571599232820.sh
+ /Users/Shared/Jenkins/Home/tools/android-sdk/platform-tools/adb remount
remount succeeded
+ /Users/Shared/Jenkins/Home/tools/android-sdk/platform-tools/adb push hosts.txt /system/etc/hosts
failed to copy 'hosts.txt' to '/system/etc/hosts': Out of memory
Build step 'Execute shell' marked build as failure
[android] Stopping Android emulator

我是否缺少一些魔法?

最佳答案

您确定 128MB 足够吗?

我刚刚创建了一个 android-15 x86 模拟器,它需要至少 220MB 左右的分区大小才能有足够的可用空间写入。

开机后可以通过adb shell df/system查看分区大小。

关于android - 无法从 Android 模拟器插件设置分区大小,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28700093/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com