Getting Error while using SQL FO Group Connection String

Pallab Chakraborty 401 Reputation points
2021-05-31T16:12:34.027+00:00

As per the article : https://learn.microsoft.com/en-us/azure/azure-sql/database/auto-failover-group-configure?tabs=azure-portal (Locate Listener Endpoint Section) it is advised to change the connection string in your Web App from the Primary DB to the SQL FO Connection string so that manual updation of the connection string is not required when the DB fails over from primary to secondary
But after using the SQL FO Group Read/Write Listener connection string, my web app is throwing the below error :


System.AggregateException: One or more errors occurred. (A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: TCP Provider, error: 0 - No such host is known.))


Can anyone please help me what is the issue here and how to resolve this

Azure SQL Database
0 comments No comments
{count} vote

Accepted answer
  1. Alberto Morillo 34,651 Reputation points MVP
    2021-05-31T17:52:53.877+00:00

    Did you took in consideration the firewall settings? The article says: "The server login and firewall settings for the secondary server must match that of your primary server".

    Configure Azure Firewall to allow Azure Services to access the Azure SQL.

    Please read here the existent documentation for network security and firewall for Azure SQL failover.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.