Azure SQL Managed Instance is fully managed SQL Server instance hosted in Azure cloud. You would need to prepare Azure environment where SQL Managed Instance will be hosted before you create your Managed Instances. In this post you will see how to deploy configured Azure environment using ARM template.
One of the most difficult tasks while creating your first managed instance is a proper configuration of Azure Virtual Network and subnet where you can create SQL Managed Instance. If you don’t configure properly your Azure network environment, your managed instance deployments might fail, or even worse your existing managed instances might be unavailable until you fix the configuration.
You would need to at least read this article to learn how to configure network for Azure SQL Managed Instance or use this quick-start script to create and configure your environment.
Since SQL Managed Instance supports ARM template deployment, you can easily deploy your environment using the button:
Once you press the “deploy to Azure” button you will be redirected to a following form:
You would need to choose a resource group and populate the following parameters:
- Name of the Azure Virtual Network that will be created and configured, including the address range that will be associated to this VNet. Default address range is 10.0.0.0/16 but you should probably change it to fit your needs.
- Name of the default subnet where you can place the resources other than Managed Instances. The name will be “Default” if you don’t want to change it. This is the subnet where you will place VMs or web apps that should access Managed Instances in your VNet. You should also enter address range that should be associated to this network. If you don’t need any other resources in your VNet you can delete this subnet later.
- Name of the subnet that will be dedicated to Managed Instances placed in your VNet including the subnet address range (this is Azure SQL Managed Instance specific requirement). Choose carefully the subnet address range because it depends on the number of instances that you would like to place in the subnet. You would need at least two addresses per every General Purpose Managed Instance that you want to deploy in the subnet.
- Name of the route table that will enable Managed Instance in the subnet to communicate with the Azure Management service that controls them. If the route table with the specified name doesn’t exist the new one will be created and configured, otherwise the existing one will be used. The recommendation is to create one route table and don’t change it.
Once you populate these fields, accept terms and conditions, and press “Purchase” button you will have fully deployed valid Azure Network environment where you can create your managed instances.
This is probably the most easiest and reliable way to create and properly configure your Azure Network environment where you can create your managed instances.