Red Gate forums :: View topic - How to reduce exceptions due to timeouts
Return to www.red-gate.com RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
SQL Comparison SDK 10
SQL Comparison SDK 10 forum

How to reduce exceptions due to timeouts

Search in SQL Comparison SDK 10 forum
Post new topic   Reply to topic
Jump to:  
Author Message
SQLAdminCJ



Joined: 28 Dec 2011
Posts: 10

PostPosted: Wed Jun 20, 2012 8:43 am    Post subject: How to reduce exceptions due to timeouts Reply with quote

Hey all,

My firm has been using the SDK to compare databases on servers at different locations. Unfortunately, it keeps crashing due to connectivity issues.

It crashes with exceptions such as:

System.Data.SqlClient.SqlException (0x80131904): A transport-level error has occurred when receiving results from the server. (provider: TCP Provider, error: 0 - The specified network name is no longer available.)

and

System.Data.SqlClient.SqlException (0x80131904): Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding.

These problems are due to intermittent connectivity issues between the servers. I imagine that if I can increase the logout time I could reduce the incidence of these crashes. However, I'm not sure whether or not to change it in the connection string in the code for the diff utility or in the parameters of the SQL server instances being compared.

Does anyone have any ideas on how I can troubleshoot this issue? I would appreciate any advice anyone can provide.

Thanks.
Back to top
View user's profile Send private message
Brian Donahue



Joined: 23 Aug 2004
Posts: 6649

PostPosted: Thu Jun 21, 2012 4:02 pm    Post subject: Reply with quote

Hello,

Even though you can adjust the timeout at the connection string, this is only the connection timeout - you are more than likely wanting to set the query timeout, which is actually hard-coded.

You can also consider avoiding Named Pipes connections, as they are an additional level of complexity over TCP/IP. If you don't need to use Named Pipes, you can force the connection to use TCP by prefacing the server name with "TCP:", for instance, use TCP:localhost for the server name.

The obvious answer is, fix the problems with the network. But that could be a complicated endeavor.
Back to top
View user's profile Send private message
SQLAdminCJ



Joined: 28 Dec 2011
Posts: 10

PostPosted: Fri Jun 22, 2012 9:34 pm    Post subject: Re: Reply with quote

This helped me understand the issue better. I will run the idea of forgoing named pipes with my manager. Thank you.

Brian Donahue wrote:
Hello,

Even though you can adjust the timeout at the connection string, this is only the connection timeout - you are more than likely wanting to set the query timeout, which is actually hard-coded.

You can also consider avoiding Named Pipes connections, as they are an additional level of complexity over TCP/IP. If you don't need to use Named Pipes, you can force the connection to use TCP by prefacing the server name with "TCP:", for instance, use TCP:localhost for the server name.

The obvious answer is, fix the problems with the network. But that could be a complicated endeavor.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic All times are GMT + 1 Hour
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group