Welcome to WuJiGu Developer Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
3.0k views
in Technique[技术] by (71.8m points)

windows - Facing Android Studio Emulator Error with AMD CPU [2021]

You open Android Studio as always, but if you would like to run an emulator device one of the following error appear:

Unable to install Android Emulator Hypervisor Driver for AMD Processors

or

Intel HAXM is required to run this AVD. Android Emulator Hypervisor Driver for AMD Processor is not installed.

or later in cmd or Powershell

[SC] DeleteService succeed. Fail of [SC] StartService error 4294967201

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

INTRODUCTION

First of all, I know that there are some posts out there. But there not up to date or incomplete. I want to point that my intention with this post is to make a nearly 100% working knowledge base for this issue. Serving as a step by step tutorial for fixing that problem properly.

Don't panic, we will fix that now :)

CHECK-1:

Check your BIOS Settings first. Virtualization Technology needs to be enabled in BIOS. Gigabyte, Asus Rog or MSI for example call that SVM Mode ("Secure Virtual Machine") other may call that as mentioned: "Virtualization"

F2/Del to access BIOS -> Advanced Settings -> CPU Configuration -> SVM Mode -> Enable, safe that with F10 (Asus BIOS Example)

BIOS Enable SVM Mode

As BIOS options are different among vendors, please refer to your system manufacturer's manual.

CHECK-2:

Type in your Windows searchbar (Lower left corner) "Windows Features". Make sure Hyper-V and Windows Hypervisor Platform are disabled. All Windows features enabling Hyper-V either explicitly or silently must be turned off. Restart your computer after. See the screenshots below for what you need to uncheck:

Uncheck the arrow marked fields

Note that in a future Studio 4.0 release, these instructions will be automatically run as part of the SDK Manager update and become obsolete.

CHECK-3:

To really ensure that Hyper-V is disabled run following command in Powershell. Open powershell: Right click on your Windows Logo (Lower left corner) -> click Windows Powershell (Administrator) -> proceed with following command:

Disable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V

SETUP ANDROID STUDIO

We now want to install the missing Hypervisor Driver for AMD Processors: In Android Studio navigate File -> Settings -> expand Appearance & Behavior -> expand System Settings -> Android SDK -> SDK Tools -> install Android Emulator Hypervisor Driver for AMD Processors (installer) -> Apply -> OK

Android Emulator Hypervisor Driver for AMD Processors (installer)

RUN THE INSTALLER

Now you downloaded the package of the driver you need to find it's location. In the image below you see the path of your Android SDK's.

Android SDK Location

Copy that path into your Explorer and navigate through like in image below to your silent_install.bat

Navigate to your silent_install.bat

Copy the complete path of your explorer and run Powershell as Administrator (how to open, explained above). In Powershell type:

cd [here your copied path]

Afterwards execute your installer by typing:

.silent_install.bat

You will probably get an error, but that isn't important, because the installer worked. We will see it later. The service only couldn't start because one of our 3 CHECKS above are not done properly. Then it will look something like that:

Installer executed

We use this "worst case" to proof that the installer operated sucessfully even with the following errors.

[SC] DeleteService succeed. Fail of [SC] StartService error 4294967201

StartService error 4294967201

They may lead you to a github directory. To download a code there, but it isn't necessary at all. It worked already. Let's try it out.

PS: If everything went as it should it will look like that (Best case):

Best Case, everything appears right but it doesn't need to

CREATING EMULATOR DEVICE

Let's create an android device and test it. I made it step by step as shown in the screenshots:

Window 1 and 2

After you selected a device you are finally able to download the android version of the device:

Window 3

Make your unique settings:

Window 4

Run your device:

Window 5

FINAL & CONCLUSION

Now you are able to work with the android studio emulator and an AMD Processor. Congratz! :) I know it was a long tutorial, but you made it trough. If you face any issues, comment below, I try to help you! That was it once again from my side. I keep this post updated.

It worked! Wuhuu :)


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to WuJiGu Developer Q&A Community for programmer and developer-Open, Learning and Share
...