Answered by:
FailOver causes "The underlying provider failed"

Question
-
We implemented database mirroring for WCF and set up failover partner in connectionstring as following
....Data Source=10.0.13.21,1433;Failover Partner=10.0.13.31,1433; ...
10.0.13.21 - primary server 10.0.13.31 - secondary server
but somehow we get error "the underlying provider failed" when the primary server is in failover state and the application is supposed to connect to secondary server. Everything works again after resetting IIS. Another strange thing is that the switch from secondary back to primary server is working but not from primary to secondary. Anybody knows possible reason for this?
thanks in advance
Monday, August 15, 2011 2:00 PM
Answers
-
Please check this article might helps you http://timheuer.com/blog/archive/2009/12/10/tips-to-deploy-ria-services-troubleshoot.aspx
http://uk.linkedin.com/in/ramjadduTuesday, August 16, 2011 12:48 PM -
Hi Angrest,
Please refer the link below:
http://www.codeproject.com/Tips/126919/Solution-for-The-underlying-provider-failed-on-Ope
Hoping this will resolve your issue.
Regards, Vishal SrivastavaSaturday, August 20, 2011 6:14 AM
All replies
-
Are you sure that logins are synchronized , can you trun on SQL Profiler and see what is going while failover is happening?
Best Regards, Uri Dimant SQL Server MVP http://dimantdatabasesolutions.blogspot.com/ http://sqlblog.com/blogs/uri_dimant/Tuesday, August 16, 2011 5:16 AM -
are they service accounts are running under same account? can you see any errors in windows event logs when you failover from primary to secondary?
http://uk.linkedin.com/in/ramjadduTuesday, August 16, 2011 9:14 AM -
thank you for the fast answer, however i dont think login is the problem. I found out that after the failover happens, if I stop sending requests and wait for a minute or two, then the application is able to open connection to secondary database, however this is not acceptable as we are running wcf application which clients use to authorize payment transactions (hundreds requests per minut), it seems to me that the invalid connection keeps hanging in the pool as requests keep coming, but i tried clearing pool after not successful try or even setting pooling to false, nothing changed.Tuesday, August 16, 2011 11:26 AM
-
Perhaps you can try setting timeout value
Refer the following link please .
http://www.mssqltips.com/tip.asp?tip=1603
Best Regards, Uri Dimant SQL Server MVP http://dimantdatabasesolutions.blogspot.com/ http://sqlblog.com/blogs/uri_dimant/Tuesday, August 16, 2011 11:30 AM -
wow, really fast answer :), thanks.
However i don't see the reason how setting timeout would help me, am I missing something? Could you explain any details?
Tuesday, August 16, 2011 11:46 AM -
Both principal and mirror are they same SQL Server editions including Patch?
http://uk.linkedin.com/in/ramjadduTuesday, August 16, 2011 11:49 AM -
yes, they are the same SQL server editions.Tuesday, August 16, 2011 12:05 PM
-
Please check this article might helps you http://timheuer.com/blog/archive/2009/12/10/tips-to-deploy-ria-services-troubleshoot.aspx
http://uk.linkedin.com/in/ramjadduTuesday, August 16, 2011 12:48 PM -
Hi Angrest,
Please refer the link below:
http://www.codeproject.com/Tips/126919/Solution-for-The-underlying-provider-failed-on-Ope
Hoping this will resolve your issue.
Regards, Vishal SrivastavaSaturday, August 20, 2011 6:14 AM