Issue
This might seem to be a duplicate of it seems too many emulator instances are running on this machine. Aborting but that question was asked 5 years ago and nothing in the answers to it have helped me. I really think this is a different situation entirely.
I'm doing something very simple. I installed Visual Studio 2019 with Xamarin and the Android emulator.
I try to start the emulator from the command line and I get...
C:\Program Files (x86)\Android\android-sdk\emulator>emulator.EXE -no-boot-anim -avd VisualStudio_android-25_x86_phone -prop monodroid.avdname=VisualStudio_android-25_x86_phone
Windows Hypervisor Platform accelerator is operational
emulator: ERROR: It seems too many emulator instances are running on this machine. Aborting.
If I add the -verbose switch I get a huge list of messages, none of which seem relevant so I haven't included them.
This is what I know:
- Windows Hyper Visor and the Platform features are enabled.
- There are no other emulators active on the machine. Ports 5554, etc are not used.
- HAXM acceleration is not enabled.
- I have plenty of memory and disk on this machine and the emulator is configured for 512MB of memory
- Genymotion emulators are not an option...I need to use Hyper V.
- Windows version 10.0.17763.678
- All patches to Android tools installed.
- No special AV installed. Using Windows Defender.
- Tried disabling firewall briefly. No help. I've never had any issue with firewall and local machine traffic.
Any ideas?
Solution
Ok...I got the emulator running. I'm really not sure what was wrong. I've spent a few days uninstalling, reinstalling, updating and finally the thing is running. To anyone else who has this issue...I feel your pain.
Here are some suggestions:
Get the code running on an actual physical phone. This worked straight away for me. This gave me some confidence that there was nothing wrong with the code or deployment.
Install and run the emulator on another dev box. Again this worked straight away. This gave me confidence there was nothing wrong with the dev box configuration that inherently prevented the emulator from running. Now I could put dev boxes side by side and investigate the divergent behavior. Did not discover any smoking guns this way, but again it built confidence.
Start the emulator directly from the command line using something like this...
c:\Program Files (x86)\Android\android-sdk\emulator>emulator -partition-size 512 -no-boot-anim -verbose -feature WindowsHypervisorPlatform -avd Android_Accelerated_x86_Nougat -prop monodroid.avdname=Android_Accelerated_x86_Nougat
Reboot/restart often. What I failed to detail in my original post is that I am using Xamarin. Long time users of Xamarin know that this stuff is really brittle. It has gotten a lot better in recent years, but this latest experience shows that it is still very tempermental and problems often disappear after restarting VS or rebooting your machine. Really demoralizing.
Good luck!
Answered By - AQuirky
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.