【问题标题】:android studio emulator: click on panel buttons causes emulator closesandroid studio模拟器:单击面板按钮会导致模拟器关闭
【发布时间】:2020-01-24 10:40:42
【问题描述】:
Android Studio 3.5
Build #AI-191.8026.42.35.5791312, built on August 9, 2019
JRE: 1.8.0_202-release-1483-b49-5587405 amd64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Linux 4.15.0-64-generic

我已经更新了我的 android studio,之后,当我点击模拟器左侧面板上的任何按钮,甚至按下 ctrl + M 打开开发者菜单时,模拟器突然关闭。

到目前为止我测试过的东西(没有一个有效):

1. installing previous version of android studio
2. choosing another avd
3. choosing another system image (api 28)
4. uninstalling android studio and installing again
5. invalidate/resetting cache  

更新:

当模拟器关闭时,我会在事件日志中看到:

2:47 PM Emulator: [26918:26918:0924/144702.703700:ERROR:zygote_host_impl_linux.cc(89)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180.

2:47 PM Emulator: Process finished with exit code 1

问题已经讨论here

【问题讨论】:

    标签: android android-studio avd avd-manager


    【解决方案1】:

    您应该能够禁用沙盒并通过将环境变量:QTWEBENGINE_DISABLE_SANDBOX 设置为 1 来解决此问题:

    export QTWEBENGINE_DISABLE_SANDBOX=1
    

    【讨论】:

      【解决方案2】:

      我在使用 Android Studio 3.5.1 和 Ubuntu 时遇到了完全相同的问题。我将模拟器从 29.1.12(运行良好)更新到 29.2.1。

      幸运的是,我有第二台计算机,使用的是以前版本的模拟器(29.1.12),所以我从 /root/Android/Sdk/emulator(默认位置)复制它,然后替换它。问题是很难找到旧版本的模拟器。如果您尝试使用比这更旧的版本,它可能无法正常工作,因此它必须是 29.1.12。我还建议在启动之前清除虚拟设备。 下次如果你真的要卸载 Android Studio 并安装以前的版本,请确保删除 /root/Android 目录。

      【讨论】:

      • 您按照步骤操作了吗?它在几台计算机上对我有用。
      猜你喜欢
      • 1970-01-01
      • 2012-10-16
      • 1970-01-01
      • 2017-07-28
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-05-09
      • 1970-01-01
      相关资源
      最近更新 更多