当前位置: 首页 > 知识库问答 >
问题:

Android Studio卡住启动模拟器

凌智
2023-03-14

我是Android开发的新手。我在编写“你好世界”程序时遇到了困难。

Android Studio在打开模拟器时被卡住了。

操作系统 - 苹果电脑专业版

它在显示以下语句后卡住了,

Waiting for device.
/Users/hiteshj/Downloads/android-sdk-macosx/tools/emulator -avd Nexus_5_API_19 -netspeed full -netdelay none

然后它显示,

/Users/hiteshj/Downloads/android-sdk-macosx/tools/emulator -avd Nexus_5_API_19 -netspeed full -netdelay none
PANIC: Missing emulator engine program for 'x86' CPUS.

与上述问题相关的一些日志(调试模式下的仿真器详细),

日志1:-

0c4de9c3b43a:~ hiteshj$ /Users/hiteshj/Downloads/android-sdk-macosx/tools/emulator -avd Nexus_5_API_19 -netspeed full -netdelay none -verbose
emulator:Found AVD name 'Nexus_5_API_19'
emulator:Found AVD target architecture: x86
emulator:Looking for emulator-x86 to emulate 'x86' CPU
emulator:Probing program: /Users/hiteshj/Downloads/android-sdk-macosx/tools/emulator-x86
PANIC: Missing emulator engine program for 'x86' CPUS.
0c4de9c3b43a:~ hiteshj$ 

日志2:-

0c4de9c3b43a:~ hiteshj$ /Users/hiteshj/Downloads/android-sdk-macosx/tools/emulator64-x86 -avd Nexus_5_API_19 -netspeed full -netdelay none -verbose
emulator: found SDK root at /Users/hiteshj/Downloads/android-sdk-macosx
emulator: Android virtual device file at: /Users/hiteshj/.android/avd/Nexus_5_API_19.ini
emulator: virtual device content at /Users/hiteshj/.android/avd/Nexus_5_API_19.avd
emulator: virtual device config file: /Users/hiteshj/.android/avd/Nexus_5_API_19.avd/config.ini
emulator: using core hw config path: /Users/hiteshj/.android/avd/Nexus_5_API_19.avd/hardware-qemu.ini
emulator: Found AVD target API level: 19
emulator: Read property file at /Users/hiteshj/Downloads/android-sdk-macosx/add-ons/addon-google_apis_x86-google-19/images/x86//build.prop
emulator: No boot.prop property file found.
emulator: found skin 'nexus_5' in directory: /Volumes/Android Studio 1.0.1/Android Studio.app/Contents/plugins/android/lib/device-art-resources
emulator: autoconfig: -skin nexus_5
emulator: autoconfig: -skindir /Volumes/Android Studio 1.0.1/Android Studio.app/Contents/plugins/android/lib/device-art-resources
emulator: writing default keyset file to /Users/hiteshj/.android/default.keyset
emulator: trying to load skin file '/Volumes/Android Studio 1.0.1/Android Studio.app/Contents/plugins/android/lib/device-art-resources/nexus_5/layout'
emulator: autoconfig: -kernel /Users/hiteshj/Downloads/android-sdk-macosx/add-ons/addon-google_apis_x86-google-19/images/x86//kernel-qemu
emulator: Auto-detect: Kernel image requires legacy device naming scheme.
emulator: Auto-detect: Kernel does support YAFFS2 partitions.
emulator: autoconfig: -ramdisk /Users/hiteshj/Downloads/android-sdk-macosx/add-ons/addon-google_apis_x86-google-19/images/x86//ramdisk.img
emulator: Using initial system image: /Users/hiteshj/Downloads/android-sdk-macosx/add-ons/addon-google_apis_x86-google-19/images/x86//system.img
emulator: autoconfig: -initdata /Users/hiteshj/.android/avd/Nexus_5_API_19.avd/userdata.img
emulator: autoconfig: -cache /Users/hiteshj/.android/avd/Nexus_5_API_19.avd/cache.img
emulator: autoconfig: -sdcard /Users/hiteshj/.android/avd/Nexus_5_API_19.avd/sdcard.img
emulator: Physical RAM size: 1536MB

emulator: CPU Acceleration: working
emulator: CPU Acceleration status: HAX (version 2) is installed and usable.
emulator: Target arch = 'x86'
emulator: Auto-config: -qemu -cpu qemu32
Content of hardware configuration file:
  hw.cpu.arch = x86
  hw.cpu.model = qemu32
  hw.ramSize = 1536
  hw.screen = touch
  hw.mainKeys = no
  hw.trackBall = no
  hw.keyboard = yes
  hw.keyboard.lid = no
  hw.keyboard.charmap = qwerty2
  hw.dPad = no
  hw.gsmModem = yes
  hw.gps = yes
  hw.battery = yes
  hw.accelerometer = yes
  hw.audioInput = yes
  hw.audioOutput = yes
  hw.sdCard = yes
  hw.sdCard.path = /Users/hiteshj/.android/avd/Nexus_5_API_19.avd/sdcard.img
  disk.cachePartition = yes
  disk.cachePartition.path = /Users/hiteshj/.android/avd/Nexus_5_API_19.avd/cache.img
  disk.cachePartition.size = 66m
  hw.lcd.width = 1080
  hw.lcd.height = 1920
  hw.lcd.depth = 16
  hw.lcd.density = 480
  hw.lcd.backlight = yes
  hw.gpu.enabled = yes
  hw.initialOrientation = portrait
  hw.camera.back = none
  hw.camera.front = none
  vm.heapSize = 64
  hw.sensors.proximity = yes
  hw.sensors.magnetic_field = yes
  hw.sensors.orientation = yes
  hw.sensors.temperature = yes
  hw.useext4 = yes
  kernel.path = /Users/hiteshj/Downloads/android-sdk-macosx/add-ons/addon-google_apis_x86-google-19/images/x86//kernel-qemu
  kernel.parameters =  androidboot.hardware=goldfish clocksource=pit android.checkjni=1
  kernel.newDeviceNaming = no
  kernel.supportsYaffs2 = yes

  disk.systemPartition.initPath = /Users/hiteshj/Downloads/android-sdk-macosx/add-ons/addon-google_apis_x86-google-19/images/x86//system.img
  disk.systemPartition.size = 550m
  disk.dataPartition.path = /Users/hiteshj/.android/avd/Nexus_5_API_19.avd/userdata-qemu.img
  disk.dataPartition.initPath = /Users/hiteshj/.android/avd/Nexus_5_API_19.avd/userdata.img
  disk.dataPartition.size = 550m
  avd.name = Nexus_5_API_19
.
QEMU options list:
emulator: argv[00] = "/Users/hiteshj/Downloads/android-sdk-macosx/tools/emulator64-x86"
emulator: argv[01] = "-netspeed"
emulator: argv[02] = "full"
emulator: argv[03] = "-netdelay"
emulator: argv[04] = "none"
emulator: argv[05] = "-enable-hax"
emulator: argv[06] = "-android-hw"
emulator: argv[07] = "/Users/hiteshj/.android/avd/Nexus_5_API_19.avd/hardware-qemu.ini"
Concatenated QEMU options:
 /Users/hiteshj/Downloads/android-sdk-macosx/tools/emulator64-x86 -netspeed full -netdelay none -enable-hax -android-hw /Users/hiteshj/.android/avd/Nexus_5_API_19.avd/hardware-qemu.ini
emulator: registered 'boot-properties' qemud service
emulator: Using kernel serial device prefix: ttyS
emulator: Ramdisk image contains fstab.goldfish file
emulator: Found format of system partition: 'ext4'
emulator: Found format of userdata partition: 'ext4'
emulator: Found format of cache partition: 'ext4'
emulator: system partition format: ext4
emulator: Mapping 'system' partition image to /tmp/android-hiteshj/emulator-Fy3cVN
emulator: nand_add_dev: system,size=0x22600000,file=/tmp/android-hiteshj/emulator-Fy3cVN,initfile=/Users/hiteshj/Downloads/android-sdk-macosx/add-ons/addon-google_apis_x86-google-19/images/x86//system.img,pagesize=512,extrasize=0
emulator: userdata partition format: ext4
emulator: nand_add_dev: userdata,size=0x22600000,file=/Users/hiteshj/.android/avd/Nexus_5_API_19.avd/userdata-qemu.img,initfile=/Users/hiteshj/.android/avd/Nexus_5_API_19.avd/userdata.img,pagesize=512,extrasize=0
emulator: cache partition format: ext4
emulator: Creating empty cache partition image at: /Users/hiteshj/.android/avd/Nexus_5_API_19.avd/cache.img
Creating filesystem with parameters:
    Size: 69206016
    Block size: 4096
    Blocks per group: 32768
    Inodes per group: 4224
    Inode size: 256
    Journal blocks: 1024
    Label: 
    Blocks: 16896
    Block groups: 1
    Reserved block group size: 7
Created filesystem with 11/4224 inodes and 1302/16896 blocks
emulator: nand_add_dev: cache,size=0x4200000,file=/Users/hiteshj/.android/avd/Nexus_5_API_19.avd/cache.img,pagesize=512,extrasize=0
emulator: registered 'boot-properties' qemud service
emulator: Adding boot property: 'dalvik.vm.heapsize' = '64m'
emulator: Adding boot property: 'qemu.sf.lcd_density' = '480'
emulator: Adding boot property: 'qemu.hw.mainkeys' = '0'
emulator: Adding boot property: 'qemu.sf.fake_camera' = 'none'
emulator: Initializing hardware OpenGLES emulation support
emulator: ERROR: Could not load OpenGLES emulation library: dlopen(lib64OpenglRender.dylib, 1): image not found
emulator: WARNING: Could not initialize OpenglES emulation, using software renderer.
HAX is working and emulator runs in fast virt mode
emulator: Kernel parameters: qemu.gles=0 qemu=1 console=ttyS0 android.qemud=ttyS1 androidboot.hardware=goldfish clocksource=pit android.checkjni=1 ndns=1
emulator:     trying to find: /Users/hiteshj/Downloads/android-sdk-macosx/tools/bios.bin

emulator:     trying to find: /Users/hiteshj/Downloads/android-sdk-macosx/tools/lib/pc-bios/bios.bin

emulator:     trying to find: /Users/hiteshj/Downloads/android-sdk-macosx/tools/vgabios-cirrus.bin

emulator:     trying to find: /Users/hiteshj/Downloads/android-sdk-macosx/tools/lib/pc-bios/vgabios-cirrus.bin

emulator: autoconfig: -scale 0.27817
emulator: Forcing ro.adb.qemud to "0".
emulator: control console listening on port 5554, ADB on port 5555
emulator: sent '0012host:emulator:5555' to ADB server
emulator: ping program: /Users/hiteshj/Downloads/android-sdk-macosx/tools/ddms
emulator: ping command: /Users/hiteshj/Downloads/android-sdk-macosx/tools/ddms ping emulator standalone "" "" ""

我还发布了一个问题,但还没有帮助。问题链接。

从过去的5天开始,我一直在同一个台阶上。请帮助我克服这个问题。

共有2个答案

丁嘉
2023-03-14

停止模拟器-

云洋
2023-03-14

正如我所看到的,您的模拟器缺少“x86”引擎的Android Studio。请检查这2点:

>

  • 验证您是否安装了该系统映像。打开您的SDK管理器并导航到Android 4.4.2文件夹。安装一切以确保:

    如果它不起作用,您还可以尝试更改模拟器的系统映像。创建一个新的虚拟设备,这次选择除“x86”以外的任何内容(如果它仍然不起作用):

    希望对你有帮助!

  •  类似资料:
    • 我昨天使用模拟器很好,但今天我不能打开模拟器。我已经阅读了android的文档和人们遇到的其他问题,但我找不到一个解决方案。我尝试使用-gpu host和-gpu swiftshader_indirect来强制仿真程序通过终端运行,但没有成功。我已经更新了所有的SDK平台和SDK工具,没有成功。我已经删除了模拟器,并通过AVD管理器安装了一个不同的模拟器,以确定下载是当前的。这里还有一些我尝试过的

    • 我有Unity 5.0.2P1个人版和Xcode 6.3.1版(6D1002)。 以下是希望重现问题的人的一些步骤: 新的空白Unity项目 IOS播放器设置>SDK版本:Simulator SDK 当应用程序在模拟器中启动时,生成和运行会产生以下结果: 警告:在路径“/users/...(用户名).../library/developer/xcode/deriveddata/unity-ipho

    • MainFormular.java 在Android.app.activity.performCreate(activity_main_formular 洛克卡特

    • 问题内容: 当我右键单击我的Android项目并选择时。模拟器启动,所做的更改确实反映出来。 但是当我执行以下以下命令时,它不会反映出来。 而且,如果没有打开模拟器,则deploy and emulator-start命令将失败。 。 这是我的android-maven-plugin-emulator-start.vbs文件。 这是我的POM.XML 问题答案: 跑之前。Maven插件无法部署到不

    • 当我尝试在iOS 8.0模拟器上使用Xcode 6 Beta 4运行我的应用程序时,总是会出现以下错误: 无法启动iOS模拟器 事实上,我在这个网站上发现了一些类似的问题,我尝试了所有的答案,但仍然无法解决。我在Xcode 6的Beta 2版本中也遇到了同样的错误,所以我决定等待。但现在这已经不正常了。有人找到了发生这种情况的原因并找到了解决方案吗?