david blaine
david blaine

Reputation: 5937

Confused by SQL error documentation, how to find cause?

I tried to login to a remote server and I saw the error given at the link -

http://www.microsoft.com/products/ee/transform.aspx?ProdName=Microsoft+SQL+Server&EvtSrc=MSSQLServer&EvtID=2

Message says -

Message: An error has occurred while establishing a connection to the server. When connecting to SQL Server, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) (.Net SqlClient Data Provider)

Which is followed by -

Explanation

SQL Server did not respond to the client request because the server is probably not started.

Arent the message and explanation contradicting each other ? Which one is the correct reason for the problem ? How do i find out the REAL source of the problem ?

Upvotes: 1

Views: 902

Answers (2)

penguat
penguat

Reputation: 1357

Thee program you are using is unable to find SQL server on the port/address it expects to. This is likely either because it is misconfigured, or because SQL server is stopped. I suggest you open a desktop login to the machine in question, and see if SQL server is running.

There are other potential causes for this problem, as well: network problems, for example.

Upvotes: 0

Daniel Hilgarth
Daniel Hilgarth

Reputation: 174329

They don't contradict each other. They just give different possible reasons:

  1. SQL Server doesn't allow remote connections
  2. SQL Server is not started

To fix it, make sure that SQL Server allows remote connections and is started.

Allowing remote connections can be done in the "SQL Server Configuration Manager":

  • Start that program on the server on which SQL server is installed.
  • Navigate to "SQL Server Network Configuration" -> "Protocols for "
  • Double click on the connection type - e.g. Named Pipes - and set "Enabled" to "Yes".
  • If you are enabling TCP/IP, make sure to also enable each individual IP address on the second tab.

See this blog post for more info.

Upvotes: 1

Related Questions