Re: Cannot generate SSPI Context error

From: Peter B.L. Rasmussen (PeterBLRasmussen_at_discussions.microsoft.com)
Date: 11/09/04


Date: Tue, 9 Nov 2004 04:28:02 -0800

Hi Kevin,

Yes, changing to Named Pipes will connect. But I would rather solve the
problem than work around it and learn something in the process. As this
problem only occurs on my development platform, and not at the production
site, I am hesitant on changing the program just to accomodate some troubles
on my site.
I don't know how to make a network trace.
Today I cannot connect at all - even after a windows logoff/logon. I have
found out that I have some old ADODB code in my program that actually
connects fine, and the connection problem only lies in .NET code connections.

If I use ADODB.ConnectionClass
And this connection string:
Provider=SQLOLEDB;Data Source=W2KServer1\VSdotNET;
Initial Catalog=Sugro011104;Integrated Security=SSPI
I can connect without any problems.

If I use System.Data.SqlClient.SqlConnection
And this Connection String:
data source=W2KServer1\VSdotNET;
initial catalog=Sugro011104;
integrated security=SSPI;
persist security info=True;
workstation id=WORKSTATION2;
packet size=4096
I cannot connect.

So maybe the solution to the problem lies somewhere in the .Net framework?

Peter

"Kevin McDonnell [MSFT]" wrote:

> Profiler won't help you tshoot the problem. You need to make network
> traces to diagnose where it is failing. An alternative is to change the
> client to use Named Pipes to connect. Named Pipes connections are able to
> natively impersonate the client without calling the SSPI API.
>
> Thanks,
>
> Kevin McDonnell
> Microsoft Corporation
>
> This posting is provided AS IS with no warranties, and confers no rights.
>
>
>
>



Relevant Pages

  • Re: netbios and named pipes sql replication.
    ... Once the client switched to named pipes, ... > connection with. ... > When we took named pipes support off the SQL server with the MS patch, ... > We had to manually walk thru the ODBC setup and configure the CLIENT ...
    (microsoft.public.sqlserver.replication)
  • Re: SQL Client protocol - not using tcp/ip
    ... my response here in case you didn't see it. ... How are you determining that the client is connecting using named pipes? ... the result of the last connection being cached. ...
    (microsoft.public.sqlserver.clients)
  • Re: netbios and named pipes sql replication.
    ... netbios connections. ... Once the client switched to named pipes, ... connection with. ... We had to manually walk thru the ODBC setup and configure the CLIENT ...
    (microsoft.public.sqlserver.replication)
  • RE: [ODBC SQL Server Driver][Shared Memory]ConnectionWrite (send()
    ... remote connection. ... should I just check named pipes only or both TCP/IP and ... I understand that you encountered the ODBC error message on your ecommerce ... TCP/IP protocol to your SQL Server instance by calling conn.Open, ...
    (microsoft.public.sqlserver.connect)
  • Re: Performance really poor if calling data from sql clients
    ... cannot see even in the profiler. ... recommendation of using TCP instead of Named Pipes to get performance. ... what is the problem with TCP as connection type? ... profiler to see what is happening on the sql server end. ...
    (microsoft.public.sqlserver.clients)

Loading