locked
Connecting to Azure SQL Database from local SQL Management Studio RRS feed

  • Question

  • Hi,

    I've created a SQL database in Azure, but cannot get connectivity to work from behind our corporate firewall.

    We've configured a VPN, and it is connected, but how do I get my local PC to route through the VPN.  When I try to connect via SQL Server management studio, the server cannot be found.  The problem I have is that the connection details for the database is xxxx.databases.windowsazure.net.  What do I need to do to instruct my connection to use the VPN as the route?  Without an IP address, I can't configure DNS.  Do I need to configure anything within the config file?

    Any help appreciated, but you will have to bear with my lack of network technology head.

    Thanks

    Tuesday, January 12, 2016 2:24 PM

Answers

  • Hi Carlton,

    At this point you cannot connect to a SQL Database via a VPN. Sorry about this but it would not be possible to connect your database to the VPN.

    Regards

    Dhruv

    Friday, January 15, 2016 7:14 PM

All replies

  • Hi Carlton,

    At this point you cannot connect to a SQL Database via a VPN. Sorry about this but it would not be possible to connect your database to the VPN.

    Regards

    Dhruv

    Friday, January 15, 2016 7:14 PM
  • First, what do you mean by "We've configured a VPN, and it is connected". There is currently no VPN support for Azure SQL Database. You can do it for Azure VMs and the VM can host a SQL Server database which is different from Azure SQL Database. Please provide more details.

    SQL Server doesn't actually have network routing configurations. It will attempt to connect over whatever network setup it is hosted on.

    Can you access the Azure portal (https://portal.azure.com/) from the same machine where your SQL Server is installed? If you can then you will be able to set a firewall rule for the Azure SQL Database server to allow your local machine to connect.


    No great genius has ever existed without some touch of madness. - Aristotle

    Friday, January 15, 2016 10:04 PM
  • Hi,

    yes, I now realise this lack of support for SQL DB over VPN.  We do have a VM running on Azure, configured to use the VPN, but didn't really want to go down the route of putting SQL server onto a VM and then having to manage that server!  Our proxy server is preventing access.  If I go off-network, I can connect to the server and work on it as required, but it's just a lot more hassle sorting that out, than working from my networked desktop.

    I had a similar problem with publishing my web app to Azure, so had to put a proxy in to my Visual Studio IDE config file.  I thought this would be the solution to the DB connection, but not.

    The problem with the firewall rule is surely it needs the IP address, and for the SQL server on Azure, you don't get that?

    Anyway, I've now got a support call with MS, so will report back if there is a fix!

    Monday, February 1, 2016 11:54 AM
  • Yup, totally get you on VPN support. Please visit https://feedback.azure.com/forums/217321-sql-database/suggestions/5537689-allow-sql-database-to-join-virtual-network-vpn and add your thoughts/votes as appropriate.

    In the meantime, have you tried using the latest SSMS preview? It has a new dialog to navigate the firewall settings if one is not already set and includes detecting the public IP you are connecting from. You can then open that one IP or a range of IPs. Check it out at https://msdn.microsoft.com/en-us/library/mt238290.aspx


    No great genius has ever existed without some touch of madness. - Aristotle

    Monday, February 1, 2016 10:19 PM