Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Installing docker on azure virtual machine windows 10

I am getting an error upon installing docker on azure virtual machine.

enter image description here

m/c configuration: azure vm, windows 10 enterprise, Intel 2.4 GHz, 7 GB RAM, 64-bit operating system, x64-based processor. I went through a few blogs and they asked me to enable nested virtualization on azure vm as follows.

Set-VMProcessor -VMName MobyLinuxVM -ExposeVirtualizationExtensions $true

But this also didn't help and the virtual m/c MobyLinuxVM failed to start. I have installed Hyper-V and Container components from windows features. But the error shows "because one of the Hyper-V components is not running" whereas all the components of Hyper-V are running. I checked the task manager performance tab and I don't see the virtualization option there. I can't modify the virtualization settings in the BIOS as I am installing docker on an Azure VM. Also I tried disabling the windows firewall but that didn't help. So how to run docker on azure virtual m/c windows 10 enterprise.

like image 803
Rajat Agrawal Avatar asked Jun 29 '17 05:06

Rajat Agrawal


People also ask

How do I install Docker on Azure Windows 10?

Download and install docker from the hub. At the end of the installation it asks you to log out and log in. Once you have logged in, wait for a minute to get the notification which asks you to enable hypervisor. Enable the hypervisor and wait for it to auto restart.

Can I install Docker on Windows 10 virtual machine?

In general, Docker recommends running Docker Desktop natively on either Mac, Linux, or Windows. However, Docker Desktop for Windows can run inside a virtual desktop provided the virtual desktop is properly configured.

How do I install Docker desktop on Azure Windows VM?

Installing Docker on an Azure Virtual Machine and Using Docker. Log in to the VM and wait for the Docker desktop icon to appear. In 2 to 3 minutes, Docker will appear to be operating. Installing Docker in an Azure Virtual Machine.


2 Answers

Here is a solution if you are getting this error on Azure Windows 10 VM where you have installed Docker:

  1. Ensure Windows Hyper-V featutes are enabled by running PowerShell cmdlet:

Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V -All -Verbose

  1. Ensure Windows Containers feature is enabled by running PowerShell cmdlet:

Enable-WindowsOptionalFeature -Online -FeatureName Containers -All -Verbose

  1. Ensure Hypervisor is set to auto start in the Boot Configuration Database (BCD) by running in elevated command prompt the command:

bcdedit /set hypervisorlaunchtype Auto

After running all of the above and you restart the Azure VM, Docker should be starting normally.

like image 108
Emil Avatar answered Oct 09 '22 08:10

Emil


Azure doesnt yet allow for nested virtualization.
You need to use DSv3 or E3 instances for that. Just use docker like you normally would

like image 38
4c74356b41 Avatar answered Oct 09 '22 10:10

4c74356b41