Unable to open SQL Server connection

Source: Internet
Author: User

Computer room toll System reconstruction version of the landing knocked for several days, finally the landing window knocked out, code debugging almost the same, the problem is in the database.

SQL Server in configuration management. SQL Server The service started, but still reported the error: a network-related or instance-specific error occurred while establishing a connection to SQL Server.

Server was not found or could not be interviewed. Verify that the instance name is correct and that SQL Server is configured to agree to a remote connection.

(provider:named Pipes provider, error:40-Unable to open connection to SQL Server)

watermark/2/text/ahr0cdovl2jsb2cuy3nkbi5uzxqvdtaxmdc4nty4nq==/font/5a6l5l2t/fontsize/400/fill/i0jbqkfcma==/ Dissolve/70/gravity/southeast ">

There is no connection to the database at all. Depressed, depressed can not solve the problem, check Bai.

The solution was finally found.

Steps to resolve:

First step: Start SQL Server network configuration inside the tcp/i, and put IP address change to your own IP address. TCPPort is 1433.


watermark/2/text/ahr0cdovl2jsb2cuy3nkbi5uzxqvdtaxmdc4nty4nq==/font/5a6l5l2t/fontsize/400/fill/i0jbqkfcma==/ Dissolve/70/gravity/southeast ">

Step two: Open SQL Server , right-click -----> aspects. Change the contents of the server configuration and the surface area configurator.

server configuration inside the remoteaccessenabled , remotedaenabled also have remoteproctransenabled all set to True

watermark/2/text/ahr0cdovl2jsb2cuy3nkbi5uzxqvdtaxmdc4nty4nq==/font/5a6l5l2t/fontsize/400/fill/i0jbqkfcma==/ Dissolve/70/gravity/southeast ">

inside the perimeter application configurator remotedaenabled set to True

watermark/2/text/ahr0cdovl2jsb2cuy3nkbi5uzxqvdtaxmdc4nty4nq==/font/5a6l5l2t/fontsize/400/fill/i0jbqkfcma==/ Dissolve/70/gravity/southeast ">

The next step is to create an exception in the firewall. The next step is to create an exception in the firewall. Open Control Panel-system and security-Windows Control Panel-approved programs.

Find yourself SQLServer.exe file folder (where the path depends on the different and different installation of each person, just to find it)

watermark/2/text/ahr0cdovl2jsb2cuy3nkbi5uzxqvdtaxmdc4nty4nq==/font/5a6l5l2t/fontsize/400/fill/i0jbqkfcma==/ Dissolve/70/gravity/southeast ">

Join complete.


finally , the pro-boot. SQL Server in configuration management. SQL Server service.

Let's see if my system can connect to the database.


No more questions. Successfully landed.

A landing. Tossing for several days, from three to seven floors. Uses the appearance mode, the abstract factory, the reflection, the configuration file, the stored procedure as well as the sqlhepler and so on all tried again.

Big and small problems have a lot, but always toss over. The various functions behind it are still more in-depth understanding of the content and continue to learn.


Unable to open SQL Server connection

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.