Error naming names when connecting to a remote Express Edition server

I am trying to connect to MS SQL Server 2008 R2 Express Edition through a remote computer. I get this error:

An error has occurred with the network or a specific instance while establishing a connection to SQL Server. The server was not found or was unavailable. Verify that the instance name is correct and SQL Server is configured for a remote connection. (provider: Named Pipes Provider, error: 40 - Could not open connection to SQL Server)

When running SELECT CONVERT(char(20), SERVERPROPERTY('InstanceName')) instancenameting

I get NULL as an instance name. I started the SQL Browser service, verified that TCP / IP is enabled.

What else can be done?

+4
source share
2 answers

Use

 Data Source=IP-0A6E3175;Network=DBMSSOCN;... 

or

 Data Source=<<ip address>>;Network=DBMSSOCN;... 

You also need to make sure that TCP / IP is enabled on the host using SQL Server Configuration Manager, that you are not blocked by a firewall, etc.

And only for kicks, please try:

 Data Source=<<ip address>>\SQLEXPRESS;Network=DBMSSOCN;... 
+2
source

In addition to the Aaron suggestion, to make sure your connection string is using tcp, start SQL Server Configuration Manager and check the following:

  • Do you have multiple instances?
  • tcp / ip enabled?
  • If the target instance is not the default instance, it will not be on port 1433, but rather some kind of dynamic port. Microsoft libraries figure out which port SQL Server Browser uses on port 1434. Your firewall should also allow this (UDP).
  • If the Express instance is the only instance, you can change it to use port 1433. Then you do not need the SQL Server browser.
+1
source

All Articles