question

pallab avatar image
1 Vote"
pallab asked AlbertoMorillo commented

Getting Error while using SQL FO Group Connection String

As per the article : https://docs.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
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

AlbertoMorillo avatar image
0 Votes"
AlbertoMorillo answered AlbertoMorillo commented

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.


· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

There was some issue from the Web App side. I was able to resolve the SQL FO Group connection string successfully. The issue got resolved now the web app is able to connect to the SQL FO Group connection string successfully. Thanks

0 Votes 0 ·

Thank you for providing your feedback, it could help others in the future.

Thank you for visiting Microsoft QA also. Have a great day!

0 Votes 0 ·