Provider named pipes provider error 40 could not open a connection to SQL Server error 2 [duplicate]

Well I have an easy solution for your question. Follow the steps:

  1. Go to SQL Server Configuration manager
  2. SQL Server Network Configuration:
  3. Protocol for MSSQLSERVER
  4. In the right pane split page you will have to disable VIA as follows
    1. Shared Memory – Enable
    2. Named Pipes – Enable
    3. TCP/IP – Enable
    4. VIA – Disable

Leave a Comment