9

I was using Windows 10 LTSB with Visual Studio 2015. After enabled Hyper-V, I installed the standalone Visual Studio Emulator for Android. The Hyper-V functioned well since it's okay to add virtual machine to it.

However, when I was trying to create an android virtual machine in the Visual Studio Emulator for Android Manager, it failed with "Unable to add user to the Hyper-V Administrators group exit code 2220".

After some research I found there's no Hyper-V Administrator group as well as no existence of InitialStorage.xml in ProgramData\Microsoft\Windows\Hyper-V\.

Was my hyper-v installation succeed? Or is there any solution for that?

Thanks everyone.

PS. logging information:

2015/8/15 12:44:53: [Informational] Reinitializing installed profiles.
2015/8/15 12:44:53: [Informational] Installed profiles initialized. Devices: 3 Platforms: 1
2015/8/15 12:44:53: [Informational] Reinitializing installable profiles.
2015/8/15 12:44:53: [Informational] Installable profiles initialized. Devices: 30 Platforms: 4
2015/8/15 12:45:00: [Informational] Waiting to uninstall device...
2015/8/15 12:45:00: [Informational] Uninstalling Device: 4.5" KitKat (4.4) HDPI Phone
2015/8/15 12:45:00: [Informational] Uninstalling virtual machine for 4.5" KitKat (4.4) HDPI Phone
2015/8/15 12:45:01: [Critical] Unable to add user to the Hyper-V Administrators group. Exit code 2220.
Clive DM
  • 551
  • 4
  • 13
  • reinstall Hyper-V and try again to setup the **Visual Studio Emulator for Android** – magicandre1981 Aug 15 '15 at 06:08
  • @magicandre1981 You mean like disable `Hypre-V` and re-enable it? – Clive DM Aug 15 '15 at 06:44
  • yes, try this. Now look if a hyper-v group was created correctly. – magicandre1981 Aug 15 '15 at 06:45
  • @magicandre1981 Have tried it. And, no, there's still no `Hyper-V Administrator` group as well as `InitialStorage.xml`. Virtual Machines works fine though. :( – Clive DM Aug 15 '15 at 07:03
  • 1
    you don't see this group? http://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-00-41-22-metablogapi/6170.image_5F00_0C4353D6.png Comment here: http://blogs.msdn.com/b/virtual_pc_guy/archive/2014/06/11/allowing-non-administrators-to-control-hyper-v-updated.aspx or contact the MS employee: http://blogs.msdn.com/b/virtual_pc_guy/contact.aspx – magicandre1981 Aug 15 '15 at 07:10
  • @magicandre1981 Nope, there's no `Hyper-V Administrator` group there. I've checked for quite a few time. Thanks for your help anyway. ;-) – Clive DM Aug 15 '15 at 08:34
  • do you use the 32Bit version? For Hyper-V you need the 64Bit Version. – magicandre1981 Aug 15 '15 at 15:24
  • @magicandre1981 Do you mean the version for the emulator? I don't think there's a choice for that: https://www.visualstudio.com/en-us/features/msft-android-emulator-vs.aspx – Clive DM Aug 15 '15 at 15:35
  • no, from Windows. You need a 64Bit Win10 Enterprise. – magicandre1981 Aug 15 '15 at 15:37
  • @magicandre1981 Yes I'm using a 64bit Windows 10 Enterprise 2015 LTSB with Hyper-V enabled and works fine – Clive DM Aug 15 '15 at 15:38
  • I have no idea. Comment in the Microsoft blog – magicandre1981 Aug 15 '15 at 15:43
  • @magicandre1981 No prob. Thanks. – Clive DM Aug 15 '15 at 15:47
  • @CliveDM, did you ever find the solution to this? – ZorleQ Mar 31 '16 at 12:32
  • 1
    I'm having the exact same problem with a fresh Windows 10 Enterprise install. I installed the Hyper-V feature before installing VS 2015 and it did not create the Hyper-V Administrators group however VMs do work properly. I did install Windows 10 using an Azure AD account when prompted which sets up the users a little bit differently which may be the issue. The problem is with the xdeprereqs executable. It makes an assumption that a Hyper-V Administrators group needs to be present however this is not the case. That executable needs to be updated. – Brett Mathe Apr 19 '16 at 00:08

2 Answers2

2

What hardware is this? Is your machine SLAT compatible? SLAT is necessary to get Hyper-V up and going.

The emulator’s Hyper-V requirement requires a processor that supports Second Level Address Translation ( SLAT ) enabled hardware. SLAT support was introduced to Hyper-V circa Windows Server 2008 as a mechanism to reduce overhead during address mapping for virtual machines. Hyper-V R2 on Windows 8/10 requires SLAT hardware, and emulators that run on SLAT do as well.

GOT SLAT?

There are two methods to check if you have SLAT hardware. The best route is download the SLATStatusCheck tool from CodePlex ( http://slatstatuscheck.codeplex.com/ ). This tool runs is a WPF 4.5 app which very simply indicates if you have SLAT compatible hardware or not. The tool is open source if you want to see how to do the checks yourself in code.

The other route is CoreInfo.exe, a tool available from SysInternals ( http://technet.microsoft.com/en-us/sysinternals/cc835722.aspx ). When you run CoreInfo.exe with a “-v” parameter, you will have a “*” next to the “EPT Supports Intel extended page tables (SLAT)” entry. Note coreinfo must be run in an admin level command prompt.

CoreInfo can sometimes lie! If you’ve already got Hyper-V running, it may erroneously return a “false negative” on the slat capabilities. CoreInfo even tells you this in a screen entry (which I overlooked) – “Note: CoreInfo must be executed on a system without a hypervisor running for accurate results”. Note that SLATStatusCheck returns the correct results regardless of whether Hyper-V is running or not.

MORE RESOURCES

Taken (mostly) from my blog post at http://blogs.msdn.com/b/devfish/archive/2012/11/06/are-you-slat-compatible-wp8-sdk-tip-01.aspx .

Joe Healy
  • 5,769
  • 3
  • 38
  • 56
  • Thanks for your help. I believe I have SLAT enabled since it's okay to deploy a virtual machine to Hyper-V and boot successful. – Clive DM Sep 02 '15 at 12:31
0

The problem may be related to the version of Windows you have or started with. You have to start with a Pro install. Upgrading from Home to Pro is incomplete.

I recently discovered if you start with the MSDN Windows 10 (Multiple Editions), Version 1607 and install it, it defaults to the Home edition. Once you put in the Pro Key to upgrade it, it becomes "Pro"; but not really. The "Users And Group" snap-in will not work, you are stuck with the security model in "Home". Once you have upgraded, you need to Reset the installation -- but do not delete/format the partition or you get a "Home" edition again.

The MSDN version does not allow you to select Home/Pro and there is no Pro version to download. Very frustrating. MS has known about this for almost a year.

Some have postulated it is because they removed a Default group definition file that included Hyper-V Administrators, but I created the group in "Home" using a Net command and it still does not work.

jlo-gmail
  • 4,453
  • 3
  • 37
  • 64