Grupos de Google ya no admite nuevas publicaciones ni suscripciones de Usenet. El contenido anterior sigue siendo visible.

Can someone please explain the logic of turning AMD-V "ON" in the BIOS, & then turning Intel Hyper-V "OFF" in "Turn Windows features on or off" just to get Android emulation to work on WIndows 10?

Visto 4 veces
Saltar al primer mensaje no leído

Arlen Holder

no leída,
12 dic 2020, 23:58:1812/12/20
a
Can someone please explain the logic of turning AMD-V "ON" in the BIOS,
& then turning Intel Hyper-V "OFF" in "Turn Windows features on or off"
just to get Android emulation to work with Android Studio on Windows 10?

I'm writing up a tutorial to help others write Android apps in emulation
o Tutorial Installing Android Studio 4.1.1 on Windows 10 (AMD CPU)
<https://groups.google.com/g/comp.mobile.android/c/g3ymz5CPsIk>

Running the obligatory "Hello World" works the first time on the actual
Android 10 device (mine is a Moto G7) hooked up via USB to Android Studio.

But it took me days (elapsed time) to get the damn emulation to work.
o The problem was the unintuitive settings necessary for AMD on Windows 10.

Specifically, you have to enter the BIOS to turn AMD virtualization "ON".
o Have you ever had a working PC that wouldn't go into the BIOS mode?
<https://groups.google.com/g/alt.comp.microsoft.windows/c/p5RvsY_M978>

And then, you have to set up Windows 10 to turn Intel virtualization "OFF".
o Can someone please help me understand the _logic_ of that necessity?

Here are some screenshots of the process, from start to finish:
o <https://i.postimg.cc/1tvysJY1/as01.jpg> "Hello World" works great in H/W
o <https://i.postimg.cc/QdqTpBsq/cmos02.jpg> Genymotion fails without AMD-V
o <https://i.postimg.cc/d1gkqrmJ/cmos03.jpg> VirtualBox fails without AMD-V
o <https://i.postimg.cc/RhSXCJQn/cmos04.jpg> Turn on AMD-V in the BIOS
o <https://i.postimg.cc/zD2nHQqQ/cmos05.jpg> Turn off Intel-V in Windows 10
o <https://i.postimg.cc/hjGjkX9X/cmos06.jpg> Android Studio uses emulation
o <https://i.postimg.cc/NF900ZCY/cmos07.jpg> Why is AMD-V on & Intel-V off?

Can someone please explain the logic of turning AMD-V "ON" in the BIOS,
& then turning Intel Hyper-V "OFF" in "Turn Windows features on or off"
just to get Android emulation to work with Android Studio on Windows 10?
--
If someone can explain the logic of what just happened, please do.

o "Your CPU is incompatible with virtualization technologies" error
<https://support.genymotion.com/hc/en-us/articles/360002737597>

o "Unable to start the Virtual Device" error
<https://support.genymotion.com/hc/en-us/articles/360002718198>

o Genymotion Desktop and Hyper-V (Windows 8/8.1/10)
<https://support.genymotion.com/hc/en-us/articles/360002732677>

Paul

no leída,
13 dic 2020, 7:26:2513/12/20
a
AMD-V (VT-X) is BIOS level virtualization support.

https://en.wikipedia.org/wiki/X86_virtualization

AMD-V VT-X "addressed the issue of privileged instructions"

AMD-Vi VT-D "(IOMMU) allows guest virtual machines to directly use peripheral devices"

SLAT EPT Second level address translation (used by Hyper-V on desktops)

Some hosting softwares have made the claim they absolutely
needed VT-X, then later, magically, they could live without it.
Maybe Windows Virtual PC or VPC2007 needed it at one time.

Hyper-V is a hosting implementation, using an inverted hypervisor.
Next year, VirtualBox will run "under" Hyper-V, so Hyper-V will call
some of the shots. It was either that as a choice, or VirtualBox
rendered non-functional. The Insider Edition forced me to
remove VirtualBox 5 (no Hyper-V support) and install VirtualBox 6
(Hyper-V support). And this is the first instance in a while, of
two hosting softwares being allowed to run at the same time. The Hyper-V
may be in usage by OS features, which is why this was done. The
era of containerization begins...

Paul

Arlen Holder

no leída,
15 dic 2020, 8:03:0415/12/20
a
On Sun, 13 Dec 2020 07:26:23 -0500, Paul wrote:

> AMD-V VT-X "addressed the issue of privileged instructions"
> Some hosting softwares have made the claim they absolutely
> needed VT-X, then later, magically, they could live without it.
> Maybe Windows Virtual PC or VPC2007 needed it at one time.

RESOLVED... (by empirical experimentation)

Hi Paul,

I figured it out by laborious trial and error, and, as usual, it turns out
you already _knew_ what I only found out by time-consuming empirical tests.

Once I had turned AMD-V on in the BIOS (which, by the way, is absolutely
essential to get Android emulation to work on my AMD HP Pavilion desktop),
then Android emulation with Genymotion & VirtualBox worked just fine.
o <https://i.postimg.cc/RhSXCJQn/cmos04.jpg> Turn on AMD-V in the BIOS

As you noted, Genymotion _insists_ I need to turn Hyper-V off in Windows
10, but in my tests, Genymotion Android Emulation (as did VirtualBox)
worked just fine whether or not I had the Intel Hyper-V stuff on or off.
o <https://i.postimg.cc/zD2nHQqQ/cmos05.jpg> Hyper-V off doesn't matter
o <https://i.postimg.cc/NF900ZCY/cmos07.jpg> Hyper-V on doesn't matter

What didn't ever work, interestingly so, was Android Studio's native Google
Android emulator, where, as with Genymotion, the Google emulator absolutely
required AMD-V to be turned on in the BIOS.

But, after that, the native Google Android emulator _still_ didn't work
properly. It would come up black and unresponsive.
o <https://i.postimg.cc/65NKJvkt/as03.jpg> Google emulator fails on AMD CPU

Lots and lots (and lots) of threads are on the net with the same problem,
which, after a few days (elapsed) time, I gave up (which is something I
rarely do).

My conclusion is Google Android emulation on older AMD CPUs, just doesn't
work. If it does, then my secondary conclusion is that it's not documented
anywhere on the net (that I can find) how to debug why it doesn't work.

More details in this post below, which I made to the Android ng just now.

UPDATE:
This is the BIOS/AMD-V firmware problem I was trying to solve (and did):
o <https://i.postimg.cc/fWSnSJXQ/cmos08.jpg> Emulation fails w/o AMD-V
o <https://i.postimg.cc/GpkgdmxT/cmos01.jpg> Access CMOS settings
o <https://i.postimg.cc/QdqTpBsq/cmos02.jpg> Genymotion needs AMD-V
o <https://i.postimg.cc/d1gkqrmJ/cmos03.jpg> VirtualBox needs AMD-V
o <https://i.postimg.cc/RhSXCJQn/cmos04.jpg> Turn on AMD-V in the BIOS
o <https://i.postimg.cc/zD2nHQqQ/cmos05.jpg> Hyper-V doesn't matter
o <https://i.postimg.cc/NF900ZCY/cmos07.jpg> Hyper-V doesn't matter
o <https://i.postimg.cc/hjGjkX9X/cmos06.jpg> Genymotion emulation working

This is the Android Studio root problem I was trying to solve:
o <https://i.postimg.cc/1tvysJY1/as01.jpg> code working on phone
o <https://i.postimg.cc/nLRWdFB1/as02.jpg> code working in Genymotion
o <https://i.postimg.cc/65NKJvkt/as03.jpg> Google emulator fails on AMD CPU
o <https://i.postimg.cc/QCQRxf2s/as04.jpg> Google emulator always offline
o <https://i.postimg.cc/qB2fL7zY/as05.jpg> Google emulator always times out
o <https://i.postimg.cc/02vTHqSN/as06.jpg> Hyper-V off doesn't matter
o <https://i.postimg.cc/Fsx2MnbV/as07.jpg> Hyper-V on doesn't matter

Once I figured out the unintuitive step of enabling AMD-V but disabling
Intel Hyper-V in Windows 10, then it was time to add the emulators.

Adding the native Android Studio emulators works fine, but they're slow.
o So below are instructions for also adding faster Genymotion emulators.

After you get your "Hello World" running on your device over USB:
o <https://i.postimg.cc/1tvysJY1/as01.jpg>

It's time to get "Hello World" running in Genymotion Android emulation:
0. For AMD CPUs, you have to turn ON the AMD-V hypervisor in your BIOS
o Win+R > msinfo32
Windows version: Windows 10, 10.0, version 2004, build: 19041
Hardware: NY549AA-ABA p6230y, HP-Pavilion, FOXCONN, ALOE
CPU: Authentic AMD AMD Phenom(tm) II X4 810
BIOS Version/Date: American Megatrends Inc. 5.02, 8/31/2009
SMBIOS Version 2.6
Hyper-V - VM Monitor Mode Extensions Yes
Hyper-V - Second Level Address Translation Extensions Yes
Hyper-V - Virtualization Enabled in Firmware Yes <== this is critical!
Hyper-V - Data Execution Protection Yes

Here are the before-and-after screenshots for BIOS enabling of AMD-V:
<https://i.postimg.cc/fWSnSJXQ/cmos08.jpg> Emulation fails w/o AMD-V
<https://i.postimg.cc/GpkgdmxT/cmos01.jpg> Access CMOS settings
<https://i.postimg.cc/QdqTpBsq/cmos02.jpg> Genymotion needs AMD-V
<https://i.postimg.cc/d1gkqrmJ/cmos03.jpg> VirtualBox needs AMD-V
<https://i.postimg.cc/RhSXCJQn/cmos04.jpg> Turn on AMD-V in the BIOS
<https://i.postimg.cc/zD2nHQqQ/cmos05.jpg> Intel-V doesn't matter
<https://i.postimg.cc/NF900ZCY/cmos07.jpg> Hyper-V doesn't matter
<https://i.postimg.cc/hjGjkX9X/cmos06.jpg> Genymotion emulation working

Note: As far as I have tested, it doesn't matter whether the Intel
hypervisor is enabled or disabled in your Windows 10 settings
(even as a zillion articles say you "must" either check or not check)
o Win+R > ms-settings:optionalfeatures > More Windows features
o Turn Windows Features on or off
[_]Core Isolation
[_]Credential Guard
[_]Hyper-V
[_]Virtual Machine Platform <== it doesn't seem to matter if checked
[_]Windows Hypervisor Platform <== doesn't seem to matter if checked
[_]Windows Sandbox
[_]Windows Subsystem for Linux version 2

1. Install & run Genymotion Personal Edition (with VirtualBox)
<https://www.genymotion.com/>
(Follow instructions at the Genymotion web site, which are pretty good.)
2. Once you have Genymotion installed & Android emulation running,
then find your SDK path (if you don't already know it)
AS:Tools > SDK Manager > Android SDK Locations
3. Set ADB in Genymotion to point to that Android SDK path
Genymotion:Settings > ADB
Change from:
(o)Use Genymotion Android Tools (default)
(_)Use custom Android SDK Tools
Change to:
(_)Use Genymotion Android Tools (default)
(o)Use custom Android SDK Tools
[Browse]C:/app/editor/android/sdk
4. In Genymotion, to add a device, press the red "(+)" sign at the top.
Choose any Android device & API to emulate & press "Install"
Once installed, press the Genymotion "Start" button to boot it.
You should get an Android emulation window after a minute or two.
5. Now install the Genymotion plugins into Android Studio:
AS:File > Settings > Plugins > Marketplace > Genymotion > Install
Restart Android Studio to apply changes to plugins.
6. Now point Android Studio to your Genymotion folder
AS:File > Tools > Emulator > Genymotion Plugin >
Select the path to the Genymotion folder
C:\app\editor\android\emu\genymotion
7. Start Genymotion from your taskbar cascade accordion foldout menu
Taskbar > menu > editor > android > genymotion
Start the emulator from inside of Genymotion's installed devices
Wait for the emulator to start in a separate window in Windows.
8. From inside Android Studio, you can now select that emulator.
Then run your code on that emulator.
<https://i.postimg.cc/nLRWdFB1/as02.jpg>

In summary, you now should have the following:
A. Android Studio runs "Hello World" on your phone over USB
<https://i.postimg.cc/1tvysJY1/as01.jpg>
B. Android Studio runs "Hello World" over Google Android emulation:
<https://i.postimg.cc/65NKJvkt/as03.jpg> Google emulator fails
<https://i.postimg.cc/QCQRxf2s/as04.jpg> Google emulator always offline
<https://i.postimg.cc/qB2fL7zY/as05.jpg> Google emulator times out
Note: It's rare for me to "just give up" but for the life of me,
I couldn't get the native AVD Android emulation to do anything
but show up blank on my AMD CPU, and, judging from the references,
many (many) people have the same (unsolved) problem set on AMD.
<https://i.postimg.cc/02vTHqSN/as06.jpg> Hyper-V off doesn't matter
<https://i.postimg.cc/Fsx2MnbV/as07.jpg> Hyper-V on doesn't matter
C. Android Studio runs "Hello World" over Genymotion emulation:
<https://i.postimg.cc/nLRWdFB1/as02.jpg>

Everything above except item "B" was relatively easy; B was impossible.
o <https://stackoverflow.com/questions/20155376/android-stop-emulator-from-command-line>
o <https://stackoverflow.com/questions/3152681/android-emulator-5554-offline>
o <https://stackoverflow.com/questions/59974253/android-studio-problem-timed-out-waiting-for-process-to-appear-on-device>
o <https://stackoverflow.com/questions/62343011/android-studio-waiting-for-all-target-devices-to-come-online-and-black-avd-err>
o <https://stackoverflow.com/questions/62560767/android-emulator-stays-with-black-screen-after-trying-a-lot-of-things-to-fix-it>
o <https://stackoverflow.com/questions/62892194/android-emulator-was-not-loading-in-android-4-0>
(etc., there are many, most unresolved or arbitrarily resolved)

All these exact same concurrent errors exist in all articles:
a. AVD pops up the Android emulator; but it is black & unresponsive.
b. STATUS: Waiting for all target devices to come online
c. ERROR: AVD Manager Timed out after 300seconds waiting for emulator to come online.
d. AS:Tools > Troubleshoot device connections > Rescan devices
Found 1 Android device(s) with possible problems:
emulator-5554 - Device is currently in the offline state
e. Win+R > cmd
c:\> adb devices
List of devices attached
emulator-5554 offline

See also:
o Have you ever had a working PC that wouldn't go into the BIOS mode?
<https://groups.google.com/g/alt.comp.microsoft.windows/c/p5RvsY_M978>

o Can someone please explain the logic of turning AMD-V "ON" in the BIOS, & then turning Intel Hyper-V "OFF" in "Turn Windows features on or off" just to get Android emulation to work on WIndows 10?
<https://groups.google.com/g/alt.comp.microsoft.windows/c/zcSpBmmc6eM>

o Tutorial Installing Android Studio 4.1.1 on Windows 10 (AMD CPU)
<https://groups.google.com/g/comp.mobile.android/c/g3ymz5CPsIk>

o Report: My first "hello world" using Android Studio freeware on Windows
<https://groups.google.com/g/comp.mobile.android/c/aW64zYeBtF0>
--
There's more value in this one post than worthless pieces of shit like Rudy
Wieser % Alan Baker, combined, have added to Usenet in their entire lives.

Arlen Holder

no leída,
15 dic 2020, 8:19:1615/12/20
a
On Tue, 15 Dec 2020 13:03:03 -0000 (UTC), Arlen Holder wrote:

> As you noted, Genymotion _insists_ I need to turn Hyper-V off in Windows
> 10, but in my tests, Genymotion Android Emulation (as did VirtualBox)
> worked just fine whether or not I had the Intel Hyper-V stuff on or off.
> o <https://i.postimg.cc/zD2nHQqQ/cmos05.jpg> Hyper-V off doesn't matter
> o <https://i.postimg.cc/NF900ZCY/cmos07.jpg> Hyper-V on doesn't matter

Ooops. As you know, I try to cite my sources (unlike the worthless pieces
of shit, who almost never even _have_ sources for what they claim), here
are my cites for that statement that Genymotion asks Hyper-V be turned off.
o Genymotion Desktop and Hyper-V (Windows 8/8.1/10)
<https://support.genymotion.com/hc/en-us/articles/360002732677>

o "An error has occurred while trying to create a virtualbox host-only
network interface" (Windows)
<https://support.genymotion.com/hc/en-us/articles/360002706697>

o "Your CPU is incompatible with virtualization technologies" error
<https://support.genymotion.com/hc/en-us/articles/360002737597>

o "Unable to start the Virtual Device" error
<https://support.genymotion.com/hc/en-us/articles/360002718198>

o How to disable Memory integrity in Windows 10?
<https://support.genymotion.com/hc/en-us/articles/360009163277>

In summary:
1. AMD-V absolutely must be on for Genymotion or Google Android emulation
2. Intel Hyper-V stuff doesn't seem to matter whether it's on or off.
--
Posted out of the goodness of my heart to help others do this more easily.
(People like Rudy Wieser & Alan Baker post out of malice in their soul.)
0 mensajes nuevos