MSSQLEXPRESS-M1-Install icon indicating copy to clipboard operation
MSSQLEXPRESS-M1-Install copied to clipboard

SQL Server Network Configuration Registry Entries Missing

Open shennerf opened this issue 2 years ago • 13 comments

jimm98y - I have used your scripts to try to install all versions except 2022 Express, and I have been unable to get TCPIP on 1433 to work. When researching - it looks like the registry entries for the instance are missing (I do see them on my Windows 10 Intel VM) - Have you seen this issue (Everything else seems to install correctly)?

shennerf avatar Jan 30 '23 23:01 shennerf

I also have the same problem, all protocols are missing, any ideas?

Gareth10jones avatar Mar 02 '23 08:03 Gareth10jones

I was able to get it to work by enabling what I could through the configuration manager, then going into the registry and manually enabling the protocols for the sqlserver entry (2019 developer). I wouldn't call it fixed as there seems to be missing settings to do it correctly through the config mgr, but the system does now work.

shennerf avatar Mar 02 '23 18:03 shennerf

@shennerf Are you able to share the exact steps and registry keys you had to add/modify to get TCP/IP to work? I have the same issue but have so far been unable to figure out what in the registry needs to be modified.

ohnv avatar Mar 09 '23 10:03 ohnv

@shennerf - that would be amazing as i'm in the same boat.

Gareth10jones avatar Mar 09 '23 14:03 Gareth10jones

So, my install is SQLServer 2019 Developer, though I would expect this will work for all of them. Also - I am connecting to it via IP from another app on the same VM - I did not test connecting to it from a different machine. The entries are not fully correct - but it does work for me when I followed these steps:

  1. Go into Windows Defender and make sure you have a rules to allow 1433 on TCP, and 1434 on UDP
  2. In SQL Server Configuration Manager - Make sure SQL Native Client 11.0 Configuration (32bit) - TCP/IP is Enabled
  3. In RegEdit - go to HKLM\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL15.MSSQLSERVER\MSSQLServer\SuperSocketNetLib\Tcp - for that entry and the ones beneath - make sure Enabled and Active are 1 for the entries you need (I just did them all)
  4. Restart and you should be good to go.

Hope this helps

shennerf avatar Mar 11 '23 00:03 shennerf

Thank you @shennerf – for me, with SQL Server 2022 Express, it was sufficient to set Enabled under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL16.SQLEXPRESS\MSSQLServer\SuperSocketNetLib\Tcp to 1 and TcpPort to 1433 under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL16.SQLEXPRESS\MSSQLServer\SuperSocketNetLib\Tcp\IPAll. (With some reservation for the fact that I did change settings back and forth, but I believe that in the end, these are the only ones that differ from the defaults.)

I did not find anything relevant at all in the SQL Server Configuration Manager to change (the mentioned configuration item was completely empty), but the registry changes turned out to be sufficient.

Obviously, for connections from outside of the virtual machine, the firewall also needs to be set to allow incoming connections to port 1433. And as remote connections with Windows Authentications may or may not work well, it might be necessary to allow SQL Server Authentication, too (under Security in Server Properties in SQL Server Management Studio).

OttoG avatar Mar 27 '23 13:03 OttoG

Thanks, OttoG and shennerf! This was simple and did the trick for me running SQLServerExpress 2022 on Windows 11 Pro version 22H2 Arm.

  1. Open regedit.exe

  2. Navigate to Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL16.SQLEXPRESS\MSSQLServer\SuperSocketNetLib\Tcp 2.1 Set DWORD Enabled value to 1

image

  1. Navigate to Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL16.SQLEXPRESS\MSSQLServer\SuperSocketNetLib\Tcp\IPAll 3.1 Set DWORD TcpPort value to 1433 or any desired port nuber

image

  1. Restart SQLServer Instance or computer

joshuadavidmcgee avatar Aug 20 '23 18:08 joshuadavidmcgee

Did anyone succeed connecting via TCP to SQL Server 2022 Developer on Win11 ARM (running inside Parallels 19 on M2)? DB seems to be running fine, but I can't connect via TCP.

I looked everywhere (I think) and tried many things, but no success.

For starters, the darn thing doesn't even know on which operating system it's running: image image

Nothing in the configuration manager: image

Remote conections are enabled: image

Edited the "Enabled" value in registry, but no success: image

Connection error:

SQLSTATE = 08001
Native Error Code = 258
[Microsoft][ODBC Driver 18 for SQL Server]A network-related or instance-specific error has occurred while establishing a connection to 10.211.55.5. Server is not found or not accessible. Check if instance name is correct and if SQL Server is configured to allow remote connections. For more information see SQL Server Books Online.

Any help appreciated!

aleks-f avatar Aug 30 '23 20:08 aleks-f

@aleks-f I have not tried the Developer edition, however it should work the same as Express. Have you tried following the above example. I only see a screenshot for step 2. The Enabled and TcpPort DWORDs are in 2 separate locations. If so did you restart the OS after? What does your connection string look like? It should be something like IPAddress,PORT example: localhost,1433

joshuadavidmcgee avatar Aug 30 '23 21:08 joshuadavidmcgee

@joshuadavidmcgee thanks for replying.

The one registry setting seems to have been enough. The problem turned to be elsewhere, in two places:

  • firewall on the server side (duh)
  • on the client side, ODBC driver 18 has encryption set to on by default:
[DRIVER={ODBC Driver 18 for SQL Server};UID=***;PWD=***;DATABASE=***;SERVER=10.211.55.5;PORT=1433;]
...
===========================
ODBC Diagnostic record #1:
===========================
SQLSTATE = 08001
Native Error Code = -1
[Microsoft][ODBC Driver 18 for SQL Server]SSL Provider: [error:0A000086:SSL routines::certificate verify failed:self-signed certificate]

===========================
ODBC Diagnostic record #2:
===========================
SQLSTATE = 08001
Native Error Code = -1
[Microsoft][ODBC Driver 18 for SQL Server]Client unable to establish connection. For solutions related to encryption errors, see https://go.microsoft.com/fwlink/?linkid=2226722

Encrypt=no fixed it:

Connected to [DRIVER={ODBC Driver 18 for SQL Server};UID=***;PWD=***;DATABASE=***;SERVER=10.211.55.5;PORT=1433;Encrypt=no]

aleks-f avatar Aug 30 '23 21:08 aleks-f

@aleks-f Hi!, I have the same problem reported by you, I use SQL Developer and I can't connect to port 1433, I've already tried all the ways described here! Did you get it to work with the Developer version?

jcstorino avatar Jan 22 '25 03:01 jcstorino

@aleks-f Hi!, I have the same problem reported by you, I use SQL Developer and I can't connect to port 1433, I've already tried all the ways described here! Did you get it to work with the Developer version?

yes

Image

aleks-f avatar Jan 25 '25 16:01 aleks-f