Error 26 : 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: SQL Network Interfaces, error: 26 – Error locating server/Instance Specified)

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: SQL Network Interfaces, error: 26 – Error locating server/Instance Specified)

Error Message:

Causes:

Server side:

  • Make sure that you have enabled remote connections on the instance (RELYONDB) of SQL Server.
  • Make sure that firewall is OFF.
  • Make sure that firewall has been configured to make an exception for SQLBROWSER.EXE and SQLSERVR.EXE in server computer.

Client side:

  • Make sure that you have typed correct server computer name and instance name
  • Make sure that server machine is reachable. Check you are able to ping the server.
  • Make sure that you are able to access the shared folder of remote server.
  • Make sure that you are able to connect SQL Server using the Telnet command.

Workaround 1:

Enable Using both TCP/IP and Named Pipes:

All programs | Microsoft SQL Server 2005| Configuration Tools | SQL Server Surface Area Configuration | Configuration for Services and Connections | Remote Connections, choose Local and Remote Connections |Enable Using both TCP/IP and Named Pipes.

Restart SQL Server RELYONDB & SQL Server Browser service.

Workaround 2:

Enable Using both TCP/IP and Named Pipes:

All programs | Microsoft SQL Server 2005| Configuration Tools | SQL Server Configuration Manager| SQL Server Network configuration| Right Click “Named Pipes” & Click Enable > Right Click “TCP\IP” & Click Enable

Restart SQL Server RELYONDB and SQL Server Browser service.

Workaround 3:

Click Start | Run | type firewall.cpl | Switch Off | Click OK.

or

Create an exception in windows firewall.

Add TCP port or sqlservr.exe to Firewall exception list, either add “..\Binn\sqlsevr.exe” or add port.

Add Sql Browser service to Firewall exception list, you can either add program ” C:\Program Files\Microsoft SQL Server\90\Shared\sqlbrowser.exe” or add UDP port 1434

Workaround 4: [Client side]

Check whether PINGing is happening in both client and server systems

Click Start | Run | type cmd| Click OK

Open command prompt as Run as Administrator | Type PING <ServerIPAddress>

Workaround 5: [Client side]

Resolve DNS cache:

Click Start | Run | type cmd| Click OK

Open command prompt as Run as Administrator |  type ipconfig /flushdns

Workaround 6: [Client side]

Give server IP address in connection string instead of hostname.

Leave a Reply

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