I have a dnn website that I'm testing a move to Azure Websites. What I wanted to do was first recreate the database on Azure and then just change the connection string to point to the azure sql database. I migrated the database just fine. It exists in my azure portal and as far as I can tell the data is accurate.
My previous connection string was:
<add name="SiteSqlServer" connectionString="Data Source={SERVERNAME};Initial Catalog={DBNAME};User ID={USERNAME};Password={PASSWORD}" providerName="System.Data.SqlClient" />
Which I changed to the azure connection as follows:
<add name="SiteSqlServer" connectionString="Data Source=tcp:{SERVERNAME}.database.windows.net,1433;Database={DBNAME};User ID={USERNAME};Password={PASSWORD};Trusted_Connection=False;Encrypt=True;Connection Timeout=30;" providerName="System.Data.SqlClient" />
But I get The following error when I try to load the site:
and the url that is hsown in the browser is: mysite.com/Install/UnderConstruction.htm
I am not sure how to trouble shoot this. Is the database not connecting or is the connection good and another problem is happening. I have not changed any files in the root of my stie. I just changed the connection string to point to the new azure database.
I can connect to this database successfully from Sql Management Studio using the connection credentials fro the connection string.
QUESTION:
How can I tell if this is a database connection issue or trouble shoot why this error appears.
Alternatively, do I need to enable a firewall access for the external IIS server IP that the site's files are hosted on?
BEGIN EDIT 1:
So I logged into my sql azure database in question and included more metrics in the monitoring page. I could see that there were connections that failed due to being blocked by the firewall, as shown below.
SO I got he IP address of the shared IIS server where my website files reside and added a firewall rule to allow that IP address. THis did not solve the problem.
Follow up Question: is there a way to tell what the ip address is of the failed connection that was blocked by the firewall?
END EDIT 1:
Thanks in advance