After upgrading to Windows 10 I can't connect to SQL server from the server itself by using the computer name

A lot of my customers told me that after upgrading their windows 7 / 8.1 machine they can't connect any more to sql server.

I replicated the problem here on a test machine and I have the same problem too.

Scenario:

Windows 8.1 + SQL Server 2014 Express.
On the server: I open Management Studio and try to connect to [ServerName]\[InstanceName]. It works.
On any client: I try to connect to [ServerName]\[InstanceName] (with a .NET application) and it works.

I do the upgrade to windows 10 on the server. After the upgrade:

On any client: I try to connect to [ServerName]\[InstanceName] and it works
On the server:

  • I open Management Studio and try to connect to [ServerName]\[InstanceName] (same operation as above). It doesn't work (timeout: cannot find the server/instance specified).
  • I open a .NET application and try to connect to [ServerName]\[InstanceName]. It doesn't work (timeout: cannot find the server/instance specified).
  • I open a command prompt and I type OSQL -S [ServerName]\[InstanceName] -E and IT WORKS.
  • I open Management Studio (or any .NET app) and try to connect to [ServerIP(V4)]\[InstanceName]. IT WORKS.

I tried to "repair" the sql server installation but it stops at the "SqlEngineDBStartConfigAction_repair_configrc_Cpu64" (I suppose it tries to connect to the just restored sql server instance to configure it) pic below:

Is there any official fix or KB article on how to fix this?

Thank you.


  • Edited by LinoB Monday, August 31, 2015 9:23 AM
August 31st, 2015 9:23am

Can you check SQl Server is up and running. Have you verified it. Can you go to SSCM and check the status of the services
Free Windows Admin Tool Kit Click here and download it now
August 31st, 2015 9:38am

Did you having the same language for Windows 10 and SQL Server ?

Was this SQL Server an upgrade ?

http://connectbeta.microsoft.com/SQLServer/feedbackdetail/view/974626/cannot-uninstall-sql-express-2014-on-windows-7-sp1

https://social.msdn.microsoft.com/Forums/en-US/70436563-31ee-40bb-9324-3f6a03e5bd3f/sql-server-express-2014-on-windows-10?forum=sqlexpress

August 31st, 2015 12:16pm

Of course it is or clients couldn't connect either.

Services:

Sql Server: Running/Automatic/"LocalSystem"
Sql Server Agent: Stopped/Other(Boot, System, Disabled or unknown)/"NT AUTHORITY\NETWORKSERVICE"
Sql Server Browser: Running/Automatic/"NT AUTHORITY\LOCALSERVICE"

Free Windows Admin Tool Kit Click here and download it now
September 1st, 2015 7:21am

Yes. Same language.

Windows 7 italian. -> Windows 10 Italian.

SQL server Express 2014 Italian.
SQL Server installed from scratch.

September 1st, 2015 7:25am

By trial and error I found where the problem actually is.

It seems that disabling SHARED MEMORY (in sql server protocols) causes the problem after upgrading to Windows 10.
Let me explain. On some windows 7 systems, with Shared memory enabled, the server couldn't connect to itself (don't ask me why).

Our setup procedure disabled shared memory protocol immediately after install leaving the server as:

  1. Shared memory (disabled)
  2. Named pipes (enabled)
  3. TCP/IP (enabled)

Client protocols, instead, were left as default (all enabled in this order SM/TCP/NP)

SQL Server on Windows 7 or Windows 8/8.1, with that configuration, works without problems. After the OS upgrade, with that configuration, you can't connect from the server to the server itself any more. Not even uninstalling and reinstalling SQL Server from scratch.

Could any of you please confirm that disabling Shared memory on Win10 prevents the connection to you too?
Can you reproduce it too?


  • Marked as answer by LinoB Tuesday, September 01, 2015 7:41 AM
  • Edited by LinoB Tuesday, September 01, 2015 8:03 AM
Free Windows Admin Tool Kit Click here and download it now
September 1st, 2015 7:39am

Confirmed - When using Windows 10 you must enable Shared Memory to allow Management Studio to connect to the local SQL database

On a Windows 10 machine, I had the same issue with connecting SQL Management Studio to a local SQL database installed on the same machine.

By default when installing SQL Express I enable TCP/IP and disable Shared Memory. 

I could connect to my local SQL Server with SQL Management Studio from another machine, but not from the local machine.  The local version could see the local server but connection to it failed

I enabled Shared Memory and then my local management studio could connect to my local SQL server.

Alternative solution - without enabling Shared Memory, in the SQL Manager if I specify my local server as "127.0.0.1\SqlInstance" instead of "GAVIN_PC\SqlInstance" (i.e. not using the local computer's name) then I can connect to it.

I expect that it is associated with the other problem with SQL Management Studio on Windows 10 - Browsing for network SQL Databases does not work - returns nothing



September 14th, 2015 5:21pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics