I am trying to work with Visual Studio Mobile App (Xamarin.Forms), so as it is said I have to enable Hyper-V on my Win 10 and then setup Visual Studio.
So I follow this and this guide in order to enable it, but after enabling Hyper-V from Settings and restarting the PC it returns disabled/unchecked.
I tried to execute bcdedit /set hypervisorlaunchtype auto in order to make it launch automatically after restart, but still not the solution. Visual Studio says that Hyper-V is disabled and can't visualize the app. Any ideas will be great. Thanks in advance.
P.S My PC is using Intel processor and in Task Manager -> Performance -> Visualization is Enabled, so not the BIOS setting is the problem.
P.S2 I tried the HAXM, but when installing it says that my PC is not compatible.
Check if "Hyper-V Virtual Machine Management" is on "Automatic" in the services.msc.
Windows key + R
Type services.msc and press OK
Search for "Hyper-V Virtual Machine Management"
Right click and click properties
Select automatic by startup type
Press apply and close
I had the same issue and this was the fix for me.
Related
Problem encountered on https://dotnet.microsoft.com/learn/xamarin/hello-world-tutorial/devicesetup
Operating System: Windows 10 Pro
Using the Hello World xamarin example in Visual Studio - I'm unable to start the Android Emulator.
When I click on the Run button in the Android Device Manager - the error appears immediately (See attached)
Error-AndroidDeviceManager (Emulator including Google Play/Google API)
Emulator error
Device error: WARNING: unexpected '-prop' value ('monodroid.avdname=pixel_2_pie_9_0_-_api_28'), only 'qemu.' properties are supported
WARNING: unexpected '-prop' value ('emu.uuid=4b63b139-cc77-4b66-9200-0d25f8fc545e'), only 'qemu.' properties are supported
Same Error when Emulator is not using Google Play/Google API
Same Error when Emulator is not using Google Play/Google API
Windows Specifications
Edition: Windows 10 Pro
Version: 1909
Processor
AMD Ryzen 9
Task Manager:
Performance: Virtualization is Enabled
cmd - systeminfo:
Hyper-V Requirements: VM Monitor Mode Extensions: Yes
Virtualization Enabled In Firmware: Yes
Second Level Address Translation: Yes
Data Execution Prevention Available: Yes
Visual Studio 2019
Windows Features On/Off (see attached - shows Hyper V / Virtualization enabled as per documentation):
WindowsFeatures
I tried this way too - adding the Virtual Machine Platform - same error
Android SDK Settings
Android SDK Version:
Could the issue be related to the Android SDK Tools - only showing Android SDK Command-line Tools versions 1.0 to 2.1?
Could the issue be related to Android Repository perhaps missing on the bottom right hand side?
I've now also included the Android SDK Repository under the tools - but this is still not coming through:
You should also check Virtual Machine Platform in Turn Windows features on or off. Also, note that the tutorial that you linked to use an Android device for USB debugging.
EDIT
Here are my Android SDK Manager settings
Platform Settings
Tools
I had also the same problem, but I have already fixed as next process.
disable both [Hyper-V] and [Windows Hypervisor Platform].
restart PC.
enable both [Hyper-V] and [Windows Hypervisor Platform].
restart PC.
I had exactly the same problem, so I went to my UEFI settings and I realized that my SVM Mode was disabled. I don't know what motherboard you have but for Gigabyte this usually is in:
M.I.T → Advanced CPU Core Settings → SVM Mode
Disable the hyper-v via the following command on command line and reboot.
bcdedit /set hypervisorlaunchtype off
Enable it back with the following command and reboot.
bcdedit /set hypervisorlaunchtype auto
Now my emulator runs!
It seems like there is some kind of conflict with virtualization as per this and it effects creating Linux VMs too but these steps clears it.
The answer by suzukimi is right but I provided the commands and some additional info.
I had the same problem, solved it by turning on the virtualization in the bios
I struggled with this issue for 2 days. I even installed Android Studio and run its own emulator to make sure the issue is not Xamarin. Finally it is solved. In my Dell laptop running Windows 10 with Hyper-V installed, there are two issues causing this:
Run Command prompt in Admin mode. type bcdedit. On the last entry all the way down, make sure hypervisorlaunchtype is Off. By default it is set to Auto.
To change this setting, type:
bcdedit /set hypervisorlaunchtype off
Make sure to run the emulator on the laptop screen. Not on any other monitor. Somehow Android emulator crashed my laptop graphics driver when it is on other monitor.
I had same issue after I brainlessly type some command which ADB I think recommend it to me. After a while a realize, that even WSL does not work (Ubuntu in WSL and Docker) so I started to troubleshoot this one and finaly find solution
DISM /Online /Enable-Feature /All /FeatureName:Microsoft-Hyper-V
bcdedit /set hypervisorlaunchtype auto
source
this typing in powershell fix all issues for me with Hyper-V and WSL
I had the same issue turns out the issue was that the intel HAXM wasn't installing properly from the SDK manager window.
So I downloaded the Installer directly from the repo. and installed it via the exe.
here: https://software.intel.com/en-us/android/articles/intel-hardware-accelerated-execution-manager
Restarted Visual studio. Worked perfectly.
Go to BIOS and enable Virtualization Technology and of course also make sure the Windows Feature (Hyper-V is installed - all components).
In my case, BIOS was reset when I changed my CPU battery.
This recently happened to me. After some research, I discovered that Microsoft Hyper V was the issue, but the machine I was trying to use it on was Windows 10 Home edition. It had to be Professional, Enterprise, etc. It's not compatible with the version of Windows. Hope this helps.
I'm using Visual Studio 2015 Enterprise with the new Android Emulator. It worked pretty well for a while but suddenly it stopped working.
The output in VS shows always this:
1>Starting emulator: VS Emulator 5.1" Lollipop (5.1.1) XXHDPI Phone
1>Validating emulator arguments...
1>Determining if emulator is already running...
1>Preparing virtual machine...
1>Launching emulator...
The emulator window appears but it stucks on the black "Loading..." screen. I see in the taskmanager that xde.exe is consuming between 25% and 32% of CPU power. There are no entries in the Windows eventlog telling anything about xde or Hyper-V.
I've already deleted all virtual computers in the Hyper-V-Manager as suggested by Microsoft on the Troubleshooting the Visual Studio Emulator for Android page.
Has anyone an idea how to get the emulator running again?
If you face the same problem then you can try to solve it by these steps:
1. Delete all virtual switches
Try it the way John Kemnetz told in his answer:
Go to Hyper-V Manager, and delete all virtual switches via the Virtual
Switch Manager 2) In Hyper-V Manager, delete all VMs. 3) Restart the
computer. 4) Start an emulator.
2. Disable network interfaces
If this doesn't work then try to do it the way Jason Smith described in a comment:
disable the network interfaces except the windows phone vswitch. Then
once the emulator is booted, turn it back on. If you delete them Xde
will recreate them, you want them created but disabled in the control
panel. The only thing to leave enabled is the windows phone one.
In case this doesn't work neither (which was my case) then
3. Reinstall Visual Studio 2015 Emulator for Android
Uninstall the emulator, reboot the PC and install it again. This worked for me. But I suggest to try the other two options first as the third option can be really time consuming.
Try this:
Go to Hyper-V Manager, and delete all virtual switches via the Virtual Switch Manager
In Hyper-V Manager, delete all VMs.
Restart the computer.
Start an emulator.
Windows 10 updates for some computers are causing problems with virtual switches and they need to be recreated by the emulator from scratch.
Have been trying to launch the Visual Studio Emulator for Android for quite some time with the continued end result of an error code from the log of either [Critical] XDE Exit Code: 16, [Critical] XDE Exit Code: 3 or an infinite "Preparing Virtual Machine" status. I've tried numerous troubleshooting guides and different device profiles but haven't had any success, nor in reproducing what has worked for others.
Running Windows 8.1 Pro 64-bit
Things I have tried:
Both Repairing and Reinstalling the Program
Reinstalling Android Studio and SDK (along with the above in various orders)
Changing Administrative Permission through Microsoft Management Console
Running XdeCleanup.exe
Creating an internal switch in Hyper-V Manager (removing in between attempts)
All of the above by "Run as Administrator"
I have been able to create a virtual machine using the Internal Switch(s) I've created in Hyper-V Manager (albeit there is nothing to boot from) and can run Virtual Box successfully so I do not believe it is a question of my BIOS setup. I would greatly appreciate any insight you could offer or a possible solution that has worked for you with this emulator. Thanks for your help.
*Note that there is no instance of Visual Studio installed on this PC (the documentation suggests that it is not required).
Screens:
You need to be a member of the Hyper-V Administrators group. Go to Control Panel and then Local Users and Groups. Add your username to the "Hyper-V Administrators" group. If no group exists, create it.
I've seen this error several times. Each time I google deeply and finally made me reinstall my windows and all stuffs. Please help, I don't want to reinstall everything again. The error is:
Windows Phone Emulator
Unable to start the Windows Phone Emulator
Windows Phone Emulator is unable to start because
the hypervisor is not running. The likely cause is
that hardware-assisted virtualization is not enabled.
Check your computer's BIOS to ensure that hardware-
assisted virtualization and hardware-assisted data
execution features are enabled.
But yesterday I debugged really normally on Windows Phone using Emulator and I really sure
I've turned on Virtualization in BIOS and also in Turn Windows features on or off :
Sometimes when I hit f5 the IDE come with another error: 0x80131500
My PC: windows 8.1 ultimate 64b, 4gb ram, i3, Visual Studio 2013 RC3
Finally after struggling all day, I solved it ^^
I post the solution here so that somebody don't have to waste time just like me to solve such a silly error!
Just simple disable Hyper-V option in Turn Windows features on or off
(you could open this by hit the combination Windows + S, this will open the search box, then type "Turn Windows features on or off"
restart your PC
enable the Hyper-V option by using the same way as step 1.
Enjoy coding :D
If the accepted answer doesn't work for you - as it unfortunately did not for me - also be sure to enable Data Execution Prevention (DEP) in your BIOS.
The article below outlines what BIOS settings to enable for Hyper-V:
https://msdn.microsoft.com/en-us/library/windows/apps/jj863509%28v=vs.105%29.aspx
In my case, I had hardware-assisted virtualization enabled in the BIOS, but not data execution prevention (DEP). I also had Hyper-V enabled via Windows Features. After enabling DEP in the BIOS, I was able to run the Windows phone emulator.
CMD with admin rights:
bcdedit /set hypervisorlaunchtype auto
and reboot.
I have a windows 8.1 installation and visual studio 2013 with windows phone sdk but when i try to debug or launch an emulator it says "The Windows emulator could not start because the the Hyper V is not runnung which is probably because hardware assisted virtuaization isnt enabled".
Whilei have triple checked that from BIOS that virtualization is enabled and using coreinfo utility i have confirmed the presence of compatible system and HYPER Visor.
Kindly help with this
Also i have the VS2013 update 1 installed
Try this.
1)Copy paste this code in notepad
bcdedit /set hypervisorlaunchtype auto
2) save it as .bat
3) run it as admin
4) restart and check whether HyperV is enabled or not