Restart your sql server and also verify that SQL SERVER Browser service must be running. April 25, 2017 SQL Server Anvesh Patel, connection, database, database research and development, dbrnd, Network related, SQL Query, SQL Server, SQL Server Administrator, SQL Server Error, SQL Server Monitoring, SQL Server Performance Tuning, SQL Server Programming, SQL Server Tips and Tricks, TSQL.
Last year our application was throwing this error when we knew for a fact the SQL server WAS up & online. We eventually traced it to a configuration in the application for a different SQL instance which no longer existed. Though we didn't use the feature the configuration was for, we had tested it, and it turned out that if the connection string is filled out the application did test the connection.Look through the apps configuration area, config files if they exist and registry. Look for the string 'ConnectionString.' This troubleshooting would be easier if Microsoft included the name if the instance it is unable to connect to in this error (hint hint).
I know this is an old thread but figured I would post here instead of creating a new one. I too am having this issue.
The odd thing is I get the error when I try to connect to the SQL Server using.NET code( VB.NET or C#). However, I tried using VB6 and it connects to the DB just fine and pulls the data(using the EXACT same connection string).Remote connections is enabled, TCP/IP and naming pipes are enabled, I added both the TCP port 1433 and UDP port 1434 enabled in windows firewall and remote connections is enabled, I'm able to ping the IP of the server as well. I just find it really really odd that I can connect via a VB6 app but not a.NET app. Does anyone have any other ideas what I can try?.
Patrick Hill-489170 (1/16/2013)I know this is an old thread but figured I would post here instead of creating a new one. I too am having this issue. The odd thing is I get the error when I try to connect to the SQL Server using.NET code( VB.NET or C#).
However, I tried using VB6 and it connects to the DB just fine and pulls the data(using the EXACT same connection string).Remote connections is enabled, TCP/IP and naming pipes are enabled, I added both the TCP port 1433 and UDP port 1434 enabled in windows firewall and remote connections is enabled, I'm able to ping the IP of the server as well. I just find it really really odd that I can connect via a VB6 app but not a.NET app. Does anyone have any other ideas what I can try?Using the EXACT same string in VB6 and.NET is probably the issue. It is very likely you don't want the same string because it is likely you are not making the same type of connection. Check out http://www.connectionstrings.com//url. Patrick Hill-489170 (1/16/2013)I know this is an old thread but figured I would post here instead of creating a new one.
I too am having this issue. The odd thing is I get the error when I try to connect to the SQL Server using.NET code( VB.NET or C#). However, I tried using VB6 and it connects to the DB just fine and pulls the data(using the EXACT same connection string).Remote connections is enabled, TCP/IP and naming pipes are enabled, I added both the TCP port 1433 and UDP port 1434 enabled in windows firewall and remote connections is enabled, I'm able to ping the IP of the server as well. I just find it really really odd that I can connect via a VB6 app but not a.NET app.
Does anyone have any other ideas what I can try?Using the EXACT same string in VB6 and.NET is probably the issue. It is very likely you don't want the same string because it is likely you are not making the same type of connection. Check out checked connectionstrings.com this is the connection string I'm using:Server=ServernameInstanceName;Database=FireSafteyTest;User Id=fsadmin;Password=.;. Patrick Hill-489170 (1/16/2013)I know this is an old thread but figured I would post here instead of creating a new one. I too am having this issue.
The odd thing is I get the error when I try to connect to the SQL Server using.NET code( VB.NET or C#). However, I tried using VB6 and it connects to the DB just fine and pulls the data(using the EXACT same connection string).Remote connections is enabled, TCP/IP and naming pipes are enabled, I added both the TCP port 1433 and UDP port 1434 enabled in windows firewall and remote connections is enabled, I'm able to ping the IP of the server as well. I just find it really really odd that I can connect via a VB6 app but not a.NET app. Does anyone have any other ideas what I can try?Using the EXACT same string in VB6 and.NET is probably the issue. It is very likely you don't want the same string because it is likely you are not making the same type of connection.
Check out checked connectionstrings.com this is the connection string I'm using:Server=ServernameInstanceName;Database=FireSafteyTest;User Id=fsadmin;Password=.;So you said you can't connect. What is the actual message? Patrick Hill-489170 (1/16/2013)I know this is an old thread but figured I would post here instead of creating a new one. I too am having this issue. The odd thing is I get the error when I try to connect to the SQL Server using.NET code( VB.NET or C#).
However, I tried using VB6 and it connects to the DB just fine and pulls the data(using the EXACT same connection string).Remote connections is enabled, TCP/IP and naming pipes are enabled, I added both the TCP port 1433 and UDP port 1434 enabled in windows firewall and remote connections is enabled, I'm able to ping the IP of the server as well. I just find it really really odd that I can connect via a VB6 app but not a.NET app. Does anyone have any other ideas what I can try?Using the EXACT same string in VB6 and.NET is probably the issue. It is very likely you don't want the same string because it is likely you are not making the same type of connection.
Check out checked connectionstrings.com this is the connection string I'm using:Server=ServernameInstanceName;Database=FireSafteyTest;User Id=fsadmin;Password=.;So you said you can't connect. What is the actual message?' A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible.
Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)'I can connect with VB 6, I can connect when I open up management studio and connect to the server.
I can even create a.udl file and connect that way. I just can't get it to connect using.netVB 6 code that connects:cn.Provider = 'sqloledb'provStr = 'Server=SSQLDBAT014001RLSOLUTIONS;Database=FireSafetyTest;User Id=fsadmin;Password=.' cn.Open provStrVB.Net Code that gives me that error:Imports System.Data.SqlClientPublic Class Form1Private Sub Form1Load(sender As System.Object, e As System.EventArgs) Handles MyBase.LoadDim cn As New SqlConnectioncn.ConnectionString = 'Server=SSQLDBAT014001RLSOLUTIONS;Database=FireSafetyTest;User Id=fsadmin;Password=.' cn.Open. Hi All,We are also getting same error message in production server intermittently.a:InternalServiceFaultA network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible.
Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)A network-related or instance-specific error occurred while establishing a connection to SQL Server.
The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. Sivarao.n (8/5/2014)Hi All,We are also getting same error message in production server intermittently.a:InternalServiceFaultA network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible.
Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections.
Hello all,i am sure this is probably been brought up on here a million times and i even google this issue but still not able to resolve this. So here is the situation.i am able to connect to this instance fine, but my co-worker using the same username/pass(SQL Server authentication) cannot connect to it.they get the below error.A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections.
(provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified) (Microsoft SQL Server, Error: -1)I even tried connection osql from cmd prompt using below.i can connect and they cannot connect.osql -S xxx.xx.xx.xxinst01 -U usernamei have looked at the server.the instance is up and running fine(obviously thats why i can connect).i folllowed couple of diff blogs.and still no resolution.below is what i followed and made sure all is doneany help is appericiated. Can the client connect to it over port the sql server listening port? You can test this from the command prompt with 'telnet '. Try this from your machine and his and compare results. A successful conenction will go to a black screen (you can type 'quit ' to exit'). An unsuccessful attempt will give an error message.this is testing connectivity from the client to the SQL Server port.
If you cant do this from the client, some firewall is blocking access over that port or the server is configured to allow connections only from certain hosts (ip filtering).you can determine what port the server is listening on by lookuing at the error log. When it first starts up, the log will show 'SQL Server is up and listening on XXXX' port. I typically see this in a client-server situation when one of the following is true:1. The instance name is spelled wrong (probably not the case here)2. UDP remote port 1434 is not set as an inbound rule on the client machine that is using Windows Firewall. This port needs to be open for the SQL Server Browser to work properly.3.
You're using aliases for your SQL Servers and the proper aliases are not set up on the client machine. If this is true in your case, you can verify what aliases are set up by running cliconfg.exe and looking under the 'Alias' tab.
Speculation is that another device is blocking access to the required port. By telneting to the port the instance is listening on you can determine whether or not there is a connectivity problem or some other problem.Suggest you check sql server error log to see which port the instance is listening on. Attempt to telnet to that port from the pc which is not connecting. If you can connect to that port via telnet, then all the talk of firewalls and network is no longer relevant. We need to look at why your client is not connecting to the sql service when you specify the name (i.e.
Serverinstance).If you cant connect via that port, then there is a networking issue. If you are certain that windows firewall is not running, then is there a phyisical device blocking connectivity over that port?
Is there a physical firewall?So, test with telnet and let us know whether there is a networking problem preventing you from accessing that port, or there is a resolution problem where you are not resolving serverinstance to the correct port. If:-Client A can connect via servernameinstance name-Client B can not connect via servernameinstance name-Cleints A and B can both connect when specifying portThen this is a SQL browser issue.
Client B must be unable to connect to the server over port 1434- so the browser can tell the client 'you are looking for a particular instance- find it on XX port'. If the windows firewall is active on the server, it must be allowing connections from Client A to port 1434, but not from Client B to port 1434. Either you can reconfigure the firewall on the server, or you can specify the port when connecting. For example, in managment studio, enter the servername as: SERVERNAME,portnumberobviously the better solution is to correct the firewall issue than to work around it by specifing the port. I have to say- I find it surprising that one client it works without specifying the port number and another you must specify the port number.
To me this means one client is allowed to access port 1434 while the other is not. Is this the case? The client which is able to connect without specifying the port number- is client actually running on the server, or this is another client PC just like the one with the problem?If I have all the information correct, and one PC can access without specifying a port, while the other must specify the port. And everything about these two clients is the same (i.e., no alias is specifed in the working client) then there must be an existing firewall rule which is allowing access to port 1434 by some host and not allowing it from others.what you want to ensure is that your SQL Server is allowing access to port 1434 from any host you wish to connect to sql server using the name. So you can either add the ip address of the new host to the list of allowed hosts, or you can do something like allow access to 1434 to ALL hosts, or all hosts on a certain subnet, etc.aspxthis is for Server 2003/xp. Basically, you are looking to ALLOW access to UDP port 1434 from ANY or from the ip address of the clients you want to be able to access sql server.