Sql Server remote connection troubleshooting

Resolving could not open a connection to SQL Server errors.

Really helpful link for troubleshooting through the issues for why you may not be able to connect to a Sql Server remotely. It steps through several possible issues. I had to google how to fix them, once I identified them, but this was a great help in discovering some of the issues.

For me, in short it was the following:

1. Make sure you have only one firewall running (I had Norton and Windows firewalls running).

Go to Windows Firewall settings and select “Advanced settings”

WindowsFirewall

Then ensure that all of the firewalls are set to off (WARNING: don’t turn off Windows firewalls unless you have another firewall running, and don’t configure firewalls unless you know what you are doing or you could lose data, your identity information, etc. If you have any doubts, get someone to help you!)

WindowsFirewallAdvancedSettings

This is how it will look after those second, redundant firewalls have been turned off.

2. Make sure the SQL Server services are enabled (SQL Server, SQL Server Browser minimally in order to see the Server on another box).

3. Enable the communication protocol that you are using (typically TCP or Named Pipes)

4. Allow port 1433 and possibly port 1434 through the firewall and limit the connection to your local subnet, or the IPs that will be connecting to the server.

5. This was the kicker for me – go into the configuration for the TCP and enable the ip addresses that you need. For me, since this server is behind a firewall, I allowed all connections.

Hope this saves someone the extra hours I spent finding out the final steps.

Advertisements

Posted on February 16, 2013, in programming, Sql Server and tagged , . Bookmark the permalink. Leave a comment.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: