Verify that the VM can access the internet. Connect the virtual machine to your virtual switches to make sure the VM has internet access.īefore we go ahead, run your new VM for the first time and complete the initial Windows installation.Set the VM to have 2 CPUs even if your machine has just 1 CPU.My laptop could barely handle 4GB of RAM for the VM but it did the trick. Set a static amount of RAM for the VM.I needed to apply some serious Google-fu: The following 4 settings are crucial for our Android dev setup and no-one really tells you about this. I won’t go into the details on how to do it as the wizard is pretty self-explanatory. Open the Hyper-V Manager and create a new VM running Windows 10 using the wizard in the Hyper-V Management application. On my machine, this was already configured correctly. The Hyper-V Management Console application allows to define “virtual switches” that map your physical network to a virtual one. Make sure Hyper-V is enabled on the host. CPU support for VM Monitor Mode Extension (VT-C on Intel CPUs).A 64-bit Processor with Second Level Address Translation (SLAT).My laptop has 8GB of RAM and I definitely felt the need for more. The Visual Studio Android Emulator requires at least 2GB of RAM in the virtual machine, so a host machine with 4GB of RAM just won’t cut it. 8GB RAM or more – According to the docs Hyper-V requires a minimum of 4GB on the host machine.Windows 10 Enterprise/Professional/Education.It worked out well but more than 8 GB RAM would have been really nice as the VM only gets 4GB of RAM on a host with 8GB of RAM. I have used my 2015 Lenovo X1 Carbon laptop for this. So here’s how to setup an Android Dev Environment using the Visual Studio Android Emulator inside a Hyper-V VM. The tricky part is that you can’t use Google’s own emulator inside a Hyper-V VM as HAXM requires Hyper-V to be disabled. All I found about this was a mere: “it’s possible”. As the lab was about our Android SDK, we need an Android Development Environment inside the VM which turns out to be rather tricky and poorly documented. The requirement for this was – we’re talking Microsoft after all – that the virtual machine uses Hyper-V, Microsoft’s own virtualization technology. For this, I needed to provide a virtual machine with the development environment that would be installed to over 40 machines inside the room where the lab took place. I did a 75 minute lab at TechReady 24, an internal conference at Microsoft this week. The caveat ist that you need to use the Visual Studio Android Emulator instead of Google’s Android Emulator. You can set up Android Studio inside a Hyper-V virtual machine.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |