Quantcast
Channel: SQLServerCentral » SQL Server 2014 » Administration - SQL Server 2014 » Latest topics
Viewing all articles
Browse latest Browse all 6525

Remote access to named instance

$
0
0
I try to connect from a pc to a SQL Server on another pc. Both pc’s are in a workgroup. I want to connect from a Windows Forms application to a named instance on the other computer. By now I have been able to connect from one pc to SQL Server on the other with tcp:smurfin, 52782.I want to be able to use servername\instancename (instead of portnumber) to make a connection in a Windows Forms application.I’ve checked / tried te following:• In the properties of the instance, tab Connections, the option Allow Remote Connections is enabled• In Configuration Manager: TCP is enabled• The service SQL Server Browser is started• On the tab IPAddresses, in the section IPAll, there is NO portnumber for TCP Port. And TCP Dynamic Ports has the nummer 52782• I have created un inbound rule for port 52782 and also for 1434 (SQL Server Browser). And to be on the save side: a rule for 1433 as well.• Restarted the serviceIf I run the following code in SQL Server, that same port number (52782) is returned:EXEC xp_ReadErrorLog 0, 1, N'Server is listening on', N'any', NULL, NULL, 'DESC'GOSELECT local_tcp_portFROM sys.dm_exec_connectionsWHERE session_id = @@SPIDGODECLARE @portNumber NVARCHAR(10)EXEC xp_instance_regread@rootkey = 'HKEY_LOCAL_MACHINE',@key = 'Software\Microsoft\Microsoft SQL Server\MSSQLServer\SuperSocketNetLib\Tcp\IpAll',@value_name = 'TcpDynamicPorts',@value = @portNumber OUTPUTSELECT [Port Number] = @portNumberGOWhat else can I do?

Viewing all articles
Browse latest Browse all 6525

Trending Articles