There are different ways to connect to SQL Managed Instance using SSMS.
One of the easiest ways to do that is using Private Endpoint. Azure SQL Managed Instance provides a private endpoint to allow connectivity from inside its virtual network. In this example we are going to use azure VM within the same Virtual Network as SQL Managed Instance.
You should create VM inside the same VNet but different subnet.
When you create SQL Managed Instance you will have following resources in you Resource Group:
As well you will have virtual network delegated to that SQL MI. Now you only need additional subnet which will be associated with your VM.
SQL MI and VM will have same virtual network and different subsets
SQL Managed Instance Virtual Network/Subnet
Azure VM Virtual Network/Subnet
Communication will be enabled between subnets within same VNet, but if you need any additional port to be open such as RDP 3389 for VM you can create inbound security rule on NSG
Last one is to run your SSMS from the VM and use your SQL MI Host name and MI admin credentials to connect to you SQL Managed Instance
If you prefer connecting to the SQL Managed Instance from your remote location using public endpoint here is the example how you can do that.
Azure SQL Managed Instances / SSMS / Connect to SQL Managed Instance / Public Endpoint
Leave a Reply