locked
SQL 2008 R2 error: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified RRS feed

  • Question

  • after some year work with SQL server 2005,i decide change to  SQL server 2008 R2.

    When i completed install SQL 2008 R2,i can't connected to SQL server due to this following 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) (.Net SqlClient Data Provider)

    And when i click to technical details,i take some thing like this

    ===================================

    Cannot connect to HUY-PC\SQLEXPRESS.

    ===================================

    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) (.Net SqlClient Data Provider)

    ------------------------------
    For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&EvtSrc=MSSQLServer&EvtID=-1&LinkId=20476

    ------------------------------
    Error Number: -1
    Severity: 20
    State: 0


    ------------------------------
    Program Location:

       at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
       at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
       at System.Data.SqlClient.TdsParser.Connect(ServerInfo serverInfo, SqlInternalConnectionTds connHandler, Boolean ignoreSniOpenTimeout, Int64 timerExpire, Boolean encrypt, Boolean trustServerCert, Boolean integratedSecurity, SqlConnection owningObject)
       at System.Data.SqlClient.SqlInternalConnectionTds.AttemptOneLogin(ServerInfo serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64 timerExpire, SqlConnection owningObject)
       at System.Data.SqlClient.SqlInternalConnectionTds.LoginNoFailover(String host, String newPassword, Boolean redirectedUserInstance, SqlConnection owningObject, SqlConnectionString connectionOptions, Int64 timerStart)
       at System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance)
       at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance)
       at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection)
       at System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup)
       at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)
       at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)
       at System.Data.SqlClient.SqlConnection.Open()
       at Microsoft.SqlServer.Management.SqlStudio.Explorer.ObjectExplorerService.ValidateConnection(UIConnectionInfo ci, IServerType server)
       at Microsoft.SqlServer.Management.UI.ConnectionDlg.Connector.ConnectionThreadUser()

    Please!!!Some body help me solve this problem(except format my computer),i really really need your advice.


    • Edited by huydaibang Wednesday, October 3, 2012 1:12 PM
    Wednesday, October 3, 2012 1:12 PM

Answers

  • Hi huydaibang,

    The older version SQL Server 2005 could be installed with SQL Server 2008 R2 side-by-side.  It could not be the problem.

    The reason that we get this error message is the client stack could not receive SSRP response UDP packet from SQL Browser.
    Here are the steps:
    1) Make sure your server name is correct, e.g., no typo on the name.
    2) Make sure your instance name is correct and there is actually such an instance on your target machine.
    3) Make sure the server machine is reachable, e.g, DNS can be resolve correctly, you are able to ping the server (not always true).
    4) Make sure SQL Browser service is running on the server.
    5) If firewall is enabled on the server, you need to put sqlbrowser.exe and/or UDP port 1434 into exception.

    For more information, please refer to http://blogs.msdn.com/b/sql_protocols/archive/2007/05/13/sql-network-interfaces-error-26-error-locating-server-instance-specified.aspx.


    Thanks,
    Maggie

     


    Please remember to mark the replies as answers if they help and unmark them if they provide no help. This can be beneficial to other community members reading the thread.

    • Marked as answer by Maggie Luo Monday, October 15, 2012 8:11 AM
    Thursday, October 4, 2012 3:27 AM

All replies

  • check that the SQL Server browser service is running, that TCP/IP and named pipes are enabled.  Is the instance local on your machine?  If not, make sure that remote connections is enabled and that any firewalls have UDP port 1434 open, and the port SQL Server's listening on.

    If this doesn't work, post back here.



    Thanks, Andrew

    Wednesday, October 3, 2012 1:36 PM
  • check that the SQL Server browser service is running, that TCP/IP and named pipes are enabled.  Is the instance local on your machine?  If not, make sure that remote connections is enabled and that any firewalls have UDP port 1434 open, and the port SQL Server's listening on.

    If this doesn't work, post back here.



    Thanks, Andrew

    Thank for you advice,i already check it out,SQL Server Browser still running,TCP/IP and name pipes are enabled too.When i install SQL 2008,i use default name instance,and remote connections is enabled too.I also shut down all kind of firewall in my computer.And nothing happen.

    And worst thing here, i can't even connect to SQL Server by Windows Authentications due same error.What Wrong????

    Do you think old version SQL 2005 is the cause of this problem?(because i still keep SQL 2005 in my computer)




    • Edited by huydaibang Thursday, October 4, 2012 2:35 AM
    Thursday, October 4, 2012 2:28 AM
  • Hi huydaibang,

    The older version SQL Server 2005 could be installed with SQL Server 2008 R2 side-by-side.  It could not be the problem.

    The reason that we get this error message is the client stack could not receive SSRP response UDP packet from SQL Browser.
    Here are the steps:
    1) Make sure your server name is correct, e.g., no typo on the name.
    2) Make sure your instance name is correct and there is actually such an instance on your target machine.
    3) Make sure the server machine is reachable, e.g, DNS can be resolve correctly, you are able to ping the server (not always true).
    4) Make sure SQL Browser service is running on the server.
    5) If firewall is enabled on the server, you need to put sqlbrowser.exe and/or UDP port 1434 into exception.

    For more information, please refer to http://blogs.msdn.com/b/sql_protocols/archive/2007/05/13/sql-network-interfaces-error-26-error-locating-server-instance-specified.aspx.


    Thanks,
    Maggie

     


    Please remember to mark the replies as answers if they help and unmark them if they provide no help. This can be beneficial to other community members reading the thread.

    • Marked as answer by Maggie Luo Monday, October 15, 2012 8:11 AM
    Thursday, October 4, 2012 3:27 AM
  • I ran into same issue with SQL2012 instance. The problem is that I can connect just fine from my laptop to the remote SQL instance. But can't connection from other sql server. Also I can connect from any where by using IP and port combination. Any idea what's going here?

    Friday, May 1, 2015 4:15 PM