0

I am having trouble to connect to SQL Server.

The SQL Server, version Express 2008 R2, was running normally until one night that server needed to restart to make some system updates (The machine runs Windows Server 2008 R2). No configuration change was made in the machine in this meantime! After this night, I couldn't connect to the SQL server any more. Neither remotely nor locally. Neither connecting through my application nor through SQL Management (SSMS). The error message was these two below, the first when I try to connect locally and the second when I try to connect remotely:

Error connecting to SQL locally via SSMS: enter image description here

Error connecting to SQL remotely via SSMS: enter image description here

The exception is one machine that is still able to connect normally to the SQL, and I can't understand the reason why.

Since yesterday i have been searching all forums trying to find a similar case that could help me solve the problem. I tried most of the suggestions that minimally fit to my problem, but I had no success.

I am desperate for, at least, a clue that guide to the solution, because I don't know what to do anymore.

Other important information is that the remote desktop is also not working for machines that don't connect to the sql server.

3
  • Can you check to see if the services are running and that the firewall allows connections? Jan 14, 2016 at 21:01
  • The service is running because, as I said, one machine is still able to connect normally (I can't connect locally and all other machines). And the firewall is off. Jan 14, 2016 at 21:08
  • What else of information can I provide to help finding out what is causing this? Jan 15, 2016 at 12:37

3 Answers 3

2

I hit the same issue after installing the following KB.

https://support.microsoft.com/en-us/kb/3081320

After following the instructions in the KB I am able to connect again.

The giveaway is Schannel error "The following fatal alert was generated: 51. The internal error state is 602."

If you see that in the System Event log (if Schannel tracing is enabled) you know you are hitting the above issue.

Good luck!

1

After days of tests I arrived to the conclusion that the error was caused by a bad update of windows server 2008 related to a security configuration. This problem affected not only SQL server, but also the remote desktop. A friend also related the exact same problem with one of his customers that he gives support. Reinstalling SQL server does not solve the problem, actually, you wont even be able to install again because an installation error will prevent you to do that.

The only way to solve the problem is repairing the windows by reinstalling it or wait for a fix update from Microsoft.

It was very disappointing having this issue, once we expect that these kind of services be more stable, specially when you use tools from the same supplier (Microsoft).

0
  1. Go to regedit
  2. Locate and then click the following subkey in the registry: HKLM\System\CurrentControlSet\Control\SecurityProviders\Schannel
  3. On the Edit menu, point to New, and then click DWORD Value.
  4. For the computer that is receiving the connection request, type DisableServerExtendedMasterSecret: REG_DWORD for the name of the DWORD, and then press ENTER.
  5. For the computer that is initiating the connection request, type DisableClientExtendedMasterSecret: REG_DWORD for the name of the DWORD, and then press ENTER.
  6. Right-click the new DWORD entry, and then click Modify. Type 1.

This will resolve this Schannel issue.

1
  • I'm receiving the error on my local machine. So my machine is both the server and the client. How can I fix this? Nov 10, 2017 at 9:49

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .