Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SQL Server 2008 Connection Error "No process is on the other end of the pipe"

Tags:

Let me begin by saying, I am aware of this thread and others around the web that seek to trouble shoot this issue.

The solutions posted there do not apply to my issue. I have spent 5 hours trying to resolve this before deciding to ask the question.

The problem: When I attempt to log into SSMS (or connect from a java application) using SQL Authentication I get this error:

A connection was successfully established with the server, but then an error occurred during the login process. (provider: Shared Memory Provider, error: 0 - No process is on the other end of the pipe.) (Microsoft SQL Server, Error: 233)

Although it does work, it is not an option for me to use integreated authentication. The database I am attempting to connect to is on the same machine as my SSMS instance. There is no network, this is a stand-alone system.

NAMED PIPES is ENABLED in my configuration, I HAVE rebooted since, TCP IP is a higher priority than named pipes in my configuration.

I have even gone as far as to uninstall SQL Server and reinstall it, to no avail.

The details of my SQL Server instance are as follows:

Microsoft SQL Server Management Studio - 10.0.2531.0 Microsoft Analysis Services Client Tools - 10.0.1600.22 Microsoft Data Access Components (MDAC)  - 6.1.7601.17514 Microsoft MSXML - 3.0 5.0 6.0  Microsoft Internet Explorer - 9.0.8112.16421 Microsoft .NET Framework - 2.0.50727.5466 Operating System     - 6.1.7601 

Configuration details are as follows: http://i45.tinypic.com/vxdz7c.png http://i45.tinypic.com/vxdz7c.jpg

I connect from java using this code.

Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver"); String connectionUrl = "jdbc:sqlserver://localhost;database=AdventureWorks;integratedSecurity=false;User=JIMBO; Password=JIMBO;"; Connection con = DriverManager.getConnection(connectionUrl); 

But please remember, this error also occurs when I atttempt to log in to SSMS directly. Thanks in advance.

-Jim

like image 406
Jimbo Avatar asked Mar 23 '13 09:03

Jimbo


People also ask

How do I fix SQL Server Error 233?

SQL Server error 233 occurs because the SQL Server client cannot connect to the server and is not configured to accept remote connections. To fix this issue, except for enabling Shared Memory and TCP/IP, we still need to activate Named Pipe protocols with SQL Server Configuration Manager tool.

How do I enable TCP IP connection in SQL Configuration Manager?

On the Start menu, click All Programs > Microsoft SQL Server 2012 > Configuration Tools > SQL Server Configuration Manager. Click SQL Server 2012 Services. Expand the SQL Server 2012 Network Configuration node, and then select Protocols for MSSQLServer (SQL Instance Name) . Right-click TCP/IP, and then click Enable.


2 Answers

To force TCP/IP being used replace localhost with 127.0.0.1 in your connection string.

As you are using a username and password make sure SQL authentication is enabled. By default only Windows integrated is enabled on sqlserver 2008.

With SqlServer authentication keep in mind that a password policy is in place to enforce security.

like image 108
rene Avatar answered Oct 26 '22 22:10

rene


Forcing the TCP/IP connection (by providing 127.0.0.1 instead of localhost or .) can reveal the real reason for the error. In my case, the database name specified in connection string was incorrect.

So, here is the checklist so far:

  • Make sure Named Pipe is enabled in configuration manager (don't forget to restart the server).
  • Make sure SQL Server Authentication (or Mixed Mode) is enabled.
  • Make sure your user name and password are correct.
  • Make sure the database you are connecting to exists.
like image 36
Mohammad Dehghan Avatar answered Oct 26 '22 22:10

Mohammad Dehghan