A Network Related Or Instance Specific Error Occurred While Establishing A Connection To SQL Server

While trying to establish a connection to SQL Server via the Microsoft SQL Server Management Studio, you can get this error:

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: Named Pipes Provider, error: 40 – Could not open a connection to SQL Server)

The network-related or instance-specific error can be caused by a few things. Here are a few troubleshooting steps for fixing errors that occur while establishing a connection to SQL Server:

  1. Check network connectivity. Can you ping the SQL Server (assuming the firewall allows IMCP Echos)? Can you establish a telenet connection to the SQL server on port 1433 (or whatever you set the port to be, 1433 is the default SQL port for single instance installations of SQL)? Does DNS resolve properly? Is there a rule in the Windows Firewall to allow SQL connections?
  2. Have you enabled remote connections to SQL Server?
  3. Is SQL Server running? Have you checked the SQL Server services?
  4. Are there any errors in the event viewer on the SQL server you are trying to establish a connection to?
VN:F [1.9.22_1171]
Rating: 0.0/10 (0 votes cast)

Leave a comment

Your email address will not be published. Required fields are marked *