Azure for AWS professionals - Virtual Machines vs EC2 instances - 03 - Creating Azure VMs
@20aman May 02, 2019Note that this post is a part of the series. You can view all posts in this series here: Azure for AWS professionals - Index
In the previous post, we covered how to create EC2 instances in AWS. You can revisit that post here: Creating EC2 Instances in AWS
In this post, we will check how to create a Virtual Machine in Azure. If you know one, it is very easy to translate the information to another platform. The essential part is to look out for the quirks of each platform and note how these differ from each other. Let's dive in.
You can create the VM resource in one of the two ways. Either by navigating to "Create a resource" and then finding the VM you want to build.
Or you can navigate to the VMs section and then click on the Add button to build the VM.
You are presented with the "Create a virtual machine" wizard. Here you ensure that the subscription and the resource group is correct. Subscription is how to buy and use Azure. You have different plans like "Pay as you go" when subscribing to Azure. Resource Groups are nothing but a logical grouping of resources in Azure.
You also provide the Instance details like the name of the VM, the region where the VM will be deployed, any redundancy options etc.
You select the VM image that you want to build e.g. Windows Server 2016 Datacenter. This is similar to selecting the AMI or Amazon machine image in AWS. The Size decides how many vCPUs and Memory in GiB is allocated to the VM. This is also how you will be billed per month for the VM. Note that you only pay when the VM is running. If the VM is in Stopped and Deallocated state then you are not charged for the Compute consumption of the VM. Then you are only charged for the storage component of the VM.
When you scroll down, this is also where you provide the credentials to be used with the VM. You also configure allowed ports for the VM. E.g. RDP is opened here. You can tweak this further in the Networking section ahead.
The biggest difference here is that, if you own a Windows license on-premises then you can leverage that to save up to 49% in Azure via Azure Hybrid Benefit.
Next, you select the VM disks. Here based on your selection you get faster and slower IOPS. You can also add new or existing disks as data disks.
In the networking section, you can select an existing Virtual network or create a new one. You can select subnets within that network or create a new one as well. Same goes for the Public IP. This is also where you can tweak the network security group.
Under the management section, you can configure Monitoring options. You can also configure Auto-shutdown configurations on the VM as well.
Under Advanced settings, you can install Microsoft or Third party extensions like Chef, Puppet etc. You can also automate one time installations in your linux VMs via Cloud init.
Next, you can assign Tags to categorize the resources. These come in very handy when creating billing reports. Note that not just the VM but underlying resources like OS and Data disks, network interface cards, etc. will also be tagged.
Finally, you can review the settings. Azure also gives you the option to "Download a template for automation". This is your ARM Template including the JSON file, that you can leverage to automate or replicate the deployment of the instance multiple times across different environments.
Then you are prompted with a screen where you can check the deployment status. Once succeeded you are provided with a link to directly navigate to the virtual machine resource.
You can now view the provisioned VM under the Virtual Machines section.
For more information, refer to the below links: Microsoft Azure Virtual Machines