M
M
Mikhri2021-01-13 10:40:18
Windows
Mikhri, 2021-01-13 10:40:18

The emulator does not start in Android Studio (details inside). How to fix?

Introductory: AMD, Win10x64, Android Studio 4.1.1.
Java is installed, on the command line and works in Eclipse.

When creating a project, an Empty Activity displays "Invalid Gradle JDK configuration found" in Sync and there are 2 options to choose from:
5ffe99a6c264b720169791.jpeg
As far as I can tell from what I googled, this problem occurs if the SDK is not specified in the project structure settings or is incorrectly specified. But both SDK and JDK are specified correctly, see the bottom spoiler.

If I choose from the proposed options to use the JDK from the project structure, then it says "BUILD SUCCESSFUL in 4s", but when I try to start the emulator from the AVD, this garbage spins endlessly:
5ffe9a2652384719118383.jpeg
By "infinitely" I mean that after a while "Timed out after 300seconds waiting for emulator to come online." pops up, but the loading animation doesn't stop spinning, nor does anything else happen for a long time.

If I choose to go to the gradle settings, then even despite their scarcity, I don’t understand what exactly should be done with them, due to the fact that I have never encountered either Gradle, or Android, or the IDE itself.
5ffe9b8f457cc866332066.jpeg
Purely for the sake of experiment, I tried using the Specified location in Use Gradle from as in Gradle home, but this did not change anything.

The Event Log advises you to look into Help | showlog. I did that, but I don't understand the meaning of the content.

spoiler

Consult IDE log for more details (Help | Show Log) (356 ms)
2021-01-13 08:57:53,826 [1704150] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 08:57:54,072 [1704396] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 08:57:54,107 [1704431] INFO - roid.tools.ndk.GradleWorkspace - Updating model took 0.002s
2021-01-13 08:57:54,403 [1704727] INFO - ge.ExternalProjectsDataStorage - Save external projects data in 108 ms
2021-01-13 08:57:54,634 [1704958] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 08:57:55,046 [1705370] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 08:57:55,546 [1705870] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 08:57:56,047 [1706371] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 08:57:56,442 [1706766] WARN - ConfigurableExtensionPointUtil - ignore deprecated groupId: language for id: preferences.language.Kotlin.scripting
2021-01-13 08:57:56,450 [1706774] WARN - ConfigurableExtensionPointUtil - use other group instead of unexpected one: language.cpp
2021-01-13 08:57:56,451 [1706775] WARN - ConfigurableExtensionPointUtil - use other group instead of unexpected one: project.propCompiler
2021-01-13 09:10:03,448 [2433772] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:03,881 [2434205] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:04,383 [2434707] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:04,884 [2435208] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:05,886 [2436210] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:06,388 [2436712] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:06,889 [2437213] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:07,390 [2437714] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:07,892 [2438216] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:08,394 [2438718] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:09,396 [2439720] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:09,897 [2440221] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:10,399 [2440723] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:10,901 [2441225] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:11,402 [2441726] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:11,903 [2442227] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:12,404 [2442728] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:12,905 [2443229] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:13,407 [2443731] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:13,909 [2444233] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:14,411 [2444735] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:14,912 [2445236] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:15,413 [2445737] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:15,914 [2446238] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:16,415 [2446739] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:16,917 [2447241] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:17,418 [2447742] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:17,920 [2448244] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:18,422 [2448746] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:18,924 [2449248] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:20,429 [2450753] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:20,928 [2451252] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:21,429 [2451753] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:37,971 [2468295] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:38,472 [2468796] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:38,554 [2468878] INFO - j.ide.actions.RevealFileAction - Exit code 1
2021-01-13 09:10:38,973 [2469297] INFO - .deployment.AsyncDevicesGetter - adb not found
2021-01-13 09:10:40,017 [2470341] INFO - .deployment.AsyncDevicesGetter - adb not found


I searched in different ways and found different tips, including, it seems to me, completely unrelated to the case, but nevertheless, out of hopelessness, I already decided to try everything in a row by typing if the described problem is similar to mine. What I did in the order of these tips, and what system parameters I checked for compliance with them:
spoiler
  • Android Studio переустановлена с промежуточной чисткой системы и реестра Ccleaner.
  • В SDK Manager загружены и установлены все Android сверху вниз до самого старого Jelly Bean включительно.
  • Intel x86 Emulator Accelerator (HAXM) установлен
  • Android Wear Intel x86 Atom System Image отдельно для Android 7.1.1 Nougat установлен.
  • В BIOS включена системная виртуализация.
  • В Windows включен Hyper-V*.
  • В структуре проекта пути - C:\Users\username\AppData\Local\Android\Sdk и C:\java\jdk15.0.1 соответственно.
  • Памяти под виртуальный девайс выделено 2 Гб (согласно рекомендациям установщика).
  • Запуск устройства без скинов тоже результатов не принес.

*
5ffe9af3af06e687774615.jpeg


At the same time, I installed AS on another machine: the installation procedure is completely the same; the system is the same Win10x64 and also under an AMD processor. And there everything worked out of the box, no "Invalid Gradle JDK configuration" appeared, the phone immediately appeared and everything works.

It becomes clear that I'm somewhere in the wrong place looking for a solution, but my level, apparently, is not enough to understand something very simple and banal, but not obvious.

So what exactly am I doing wrong and what should I do to get this damn emulator running in Android Studio on this particular machine?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
Q
qqweer, 2021-01-13
@hawkkiller

1.JAVA_HOME is written to the environment variables with a reference to java jdk? Java jdk is not jre.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question