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.
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