Skip to content Skip to sidebar Skip to footer

Ssms 17 Windows Cannot Find Hlpviewerexe Make Sure You Typede Hte Name Correctly and Try Again

Resolving could non open a connectedness to SQL Server errors

Past:   |   Updated: 2019-05-29   |   Comments (84)   |   Related: i | ii | 3 | More > SQL Server Configurations



Problem

Sometimes you lot may accept issues connecting to SQL Server and y'all may go messages such as the post-obit:

ERROR: (provider: Named Pipes Provider, mistake: forty - Could not open a connection to SQL Server) (Microsoft SQL Server, Fault:) An error has occurred while establishing a connection to the server. (provider: Named Pipes Provider, error: forty - Could not open up a connectedness to SQL Server) (Microsoft SQL Server, Error: v)

Or

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that nether the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) (Microsoft SQL Server, Error: 1326)

Or

A network-related error or instance-specific error occurred while establishing a connexion to SQL Server. The server was not found or was not accessible. Verify that the case proper name is right and that SQL Server is configured to allow remote connections. (provider: TCP Provider, error: 0 - No such host is known.) (Microsoft SQL Server, Fault: 11001)

These errors could be for either Named Pipes connections or TCP/IP connections. In this tip, we look at what may be causes to these errors and how to resolve.

Solution

At that place could be several reasons you lot get these error messages. Follow the below steps to see if you can resolve the outcome.

Footstep 1 - Bank check that you can ping the SQL Server box

Make sure y'all are able to ping the physical server where SQL Server is installed from the client machine. If not, you can attempt to connect to the SQL Server using an IP Address (for default example) or IP Address\Instance Proper noun for a named example.

resolving issues connecting to sql server

If it resolves using an IP address, you can add the SQL Server machine into /etc/host file. To add the entry in the /host file type %SystemRoot%\system32\drivers\etc\ in the run window and open the host file using Notepad. In the below image I added IP address 74.200.243.253 with a motorcar proper name of SQLDBPool. At present I should be able to use the machine name instead of the IP address to connect to the SQL Server.

try to connect to the sql server using an ip address

Step 2 - Check that the SQL Services are running

Make certain the SQL services are running Y'all can bank check the SQL Server services past using the SC command or SQL Server Configuration Manager. Many times you lot may detect that the SQL Server instance is not running.

Using SQL Server Configuration Manager

You tin can use SQL Server Configuration Managing director to make certain the services are running.  If for some reason you cannot find SQL Server Configuration Manager check out this commodity.

using sql server configuration manager

sql server configuration manager

Using SC command

From a Windows control line you can issue the post-obit control to see the status of the services.

using the sc command to check that sql services are running

Please notation for a named case you take to write the command every bit follows using the correct case name, by replacing instancename with the actual SQL Server instance name.

sc query mssql$instancename            

Step iii - Check that the SQL Server Browser service is running

Cheque that the SQL Server Browser service is running. If you have installed a SQL Server named instance and not configured a specific TCP/IP port, incoming requests will be listening on a dynamic port. To resolve this you will demand to have the SQL Server Browser service enabled and running. You tin check the browser service status using either SQL Server Configuration Manager or the SC control as follows.

check that the sql browser service is running

Stride 4 - Cheque that y'all are using the correct SQL Server instance name

Brand sure you are using the correct instance name. When you connect to a default instance, machinename is the all-time representative for the instance name and when you connect to a named example such as sqlexpress, you need to specify the instancename as follows: machinename\instancename where yous enter the SQL Server instance name for instancename.

Stride 5 - Check that you tin find the SQL Server

Check that SQL Server is in the network. You lot can use the SQLCMD -Fifty control to retrieve the list of SQL Servers installed in the network. Note that this will merely render SQL Servers if the SQL Server Browser service is running.

use the sqlcmd-L to check that sql server is in the network

Step 6 - Check that TCP/IP and Named Pipes are enabled

Check the TCP/IP and Named Pipes protocols and port. Open SQL Server Configuration Manager and bank check the SQL Server Network Configuration protocols. You should enable Named Pipes and TCP/IP protocol.

open ssms and check the sql server network configuration protocols

For the TCP/IP protocol, correct click and select properties to check the TCP/IP advice port likewise. The default port is 1433, which can be changed for security purposes if needed.

check the tcp/ip communication port

Step seven - Check that allow remote connections for this server is enabled

Check to see if allow remote connections for this server is enabled. In SSMS, right click on the instance name and select Properties. Become to the Connections tab and make sure Allow remote connections to this server is checked. If you lot demand to brand a alter, you must restart the SQL Server instance to apply the alter.

in ssms select properties and go to the connections tab

You tin can also configure the remote server connections using the below commands. If y'all make changes you will demand to restart SQL Server for these to take affect.

The settings below are equivalent to the settings in the paradigm above.

exec sp_configure "remote access", 1          -- 0 on, i off exec sp_configure "remote query timeout", 600 -- seconds exec sp_configure "remote proc trans", 0      -- 0 on, 1 off            

Stride 8 - Check the port number that SQL Server is using

 Locally connect to SQL Server and cheque the fault log for the port entry. You can execute XP_READERRORLOG procedure to read the errors or use SSMS by going to Management > SQL Server Logs and select the Current log. Scroll to the bottom which will be the kickoff entries in the error log and look for entries similar to below that shows Named Pipes and TCP/IP are enabled and the port used for TCP/IP which is 1433 in this instance.

locally connect to sql server and check the error log

Stride nine - Check that the firewall is not blocking admission to SQL Server

Configure the Windows Firewall for the SQL Server port and SQL Server Browser service. Become to Control Panel and click on  Windows Firewall.  Get to exceptions tab every bit shown below. Yous can read this tip Configure Windows Firewall to Work with SQL Server for more information.

configure the windows firewall for the sql server port and sql browser service

Click on Add Port... and enter the port number and name.

enter the port number and name

Click on Add Program... to add the SQL Server Browser service. Here yous need to go the browser service executable path, ordinarily information technology is located at C:\Program Files\Microsoft SQL Server\xc\Shared location for SQL 2005 or similar for other versions of SQL Server. Browse the location and add together the SQLBrowser.exe in the exception list.

add the sql browser service

Footstep 10 - Bank check that the Service Principal Proper noun has been registered

If you lot are able to connect to SQL Server by physically logging on to the server, simply unable to connect from a client calculator then execute the below query in a query window to check the SPN.

-- run this command to see if SPN is not found EXEC xp_readerrorlog 0,1,"could not register the Service Chief Name",Cipher            

If the SPN is non found, read this Annals a Service Principal Name for Kerberos Connections and this How to Configure an SPN for SQL Server Site Database Servers for more details about how to setup and register an SPN.

Side by side Steps
  • Side by side fourth dimension you have issues connecting, cheque these steps to resolve the event.
  • Related tips:
    • Understanding SQL Server Net-Libraries

Related Articles

Popular Manufactures

About the writer

MSSQLTips author Jugal Shah Jugal Shah has 8+ years of extensive SQL Server experience and has worked on SQL Server 2000, 2005, 2008 and 2008 R2.

View all my tips

Article Concluding Updated: 2019-05-29

davisthoulladay.blogspot.com

Source: https://www.mssqltips.com/sqlservertip/2340/resolving-could-not-open-a-connection-to-sql-server-errors/

Post a Comment for "Ssms 17 Windows Cannot Find Hlpviewerexe Make Sure You Typede Hte Name Correctly and Try Again"