0

I have created an Azure SQL Managed Instance but I am unable to create a VM to connect to it as I need to put it on the same Subnet.

When I try to do so I am not given the option. I can select the virtual network that was created with my Managed Instance but when I attempt to select the 'ManagedInstance' Subnet it's greyed out...

ManagedInstance (10.0.0.0/24) (The selected subnet is not supported)

Looking at the vnet (created automatically when I set up my managed instance) it's Address space is clashing but I can't change the Address space because the subnet is using it - I can't change the subnet because the range isn't in the address space (and so on and so forth)

I seem to be stuck in a chicken / egg nightmare

I don't know what other info I can give at this time.

Keith Jackson
  • 3,078
  • 4
  • 38
  • 66

2 Answers2

1

With new Azure SQL MI deployments, the subnet for MI is reserved for MI and you should keep it that way. Create the VM on a different subnet within the same VNET.

One the of challenges that I have seen putting resources in the same subnet as MI is that MI requires at least 8 IP addresses. Best practice dictates to keep at least 16 IP available for MI.

These are some resources for some visibility

https://learn.microsoft.com/en-us/azure/azure-sql/managed-instance/virtual-network-subnet-create-arm-template

https://learn.microsoft.com/en-us/azure/azure-sql/managed-instance/vnet-subnet-determine-size

Rizwan
  • 318
  • 1
  • 5
  • One other I forgot to mention, As long as the VM is deployed in the same VNET but on a different subnet, it will be able to communicate with SQL MI – Rizwan Nov 25 '20 at 23:35
0

The VM and the Managed Instance need to be on the same VNET but not on the same Subnet - You need to create a separate subnet for each to live on.

The clashing Address space was a nasty one though - I couldn't find a fix for that and had to tear down everything and start again with a new VNET which I created before deploying the Managed Instance.

Keith Jackson
  • 3,078
  • 4
  • 38
  • 66