Search

Monday, January 11, 2016

Error: 64, connection was successfully established with the server, but then an error occurred during the pre-login handshake.

I had got below error in my friend's system:

A connection was successfully established with the server, but then an error occurred during the pre-login handshake. (provider: TCP Provider, error: 0 – The specified network name is no longer available.) (Microsoft SQL Server, Error: 64)

I googled this error and got mixed results and solutions but none solved my problem.


After some more googling I found below solution that worked for me.
The solution is:
Go to the MSSQL Configuration Manager and expand the SQL Network Configuration and click on the PROTOCOLS node. Right click on TCP/IP and open up the PROPERTIES panel and Select the IP ADDRESS tab.
Check the IP ADDRESS field's value are correct and match the system it is running on.
Restart the service, and the problem is solved.
Make sure you fill in the TCP PORT, even if you are using the default 1433.

11 comments:

  1. This is great if your running windows. But how does one do this using sqlcmd on a Linux server running this in a container. I'm getting this exact error message attempting to connect from my machine using SSMS to a remove RHEL 7 server that hosts my SQL container.

    There is no MSSQL Configuration Manager GUI.

    ReplyDelete