Notice: This website is an unofficial Microsoft Knowledge Base (hereinafter KB) archive and is intended to provide a reliable access to deleted content from Microsoft KB. All KB articles are owned by Microsoft Corporation. Read full disclaimer for more details.

FIX: Error message when you use the SQL Server Native Client provider to run queries between two linked servers in SQL Server 2005 Service Pack 1: "Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'"


Summary

This article describes the following about this hotfix release:
  • The issues that are fixed by the hotfix package
  • The prerequisites for applying the hotfix package
  • Information about whether you must restart the computer after you apply the hotfix package
  • Information about whether the hotfix package is replaced by any other hotfix package
  • Information about whether you must make any registry changes after you apply the hotfix package
  • The files that are contained in the hotfix package

↑ Back to the top


Symptoms

In Microsoft SQL Server 2005 Service Pack 1 (SP1), you use the SQL Server Native Client provider to run queries between two SQL Server 2005 linked servers. After you do this, you may receive the following error message:
Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'
You receive this error message if the following conditions are true:
  • You use the TCP/IP protocol.
  • You enable Kerberos authentication for the connection between the linked computers.
Typically, all other queries in the session fail and you receive the same error message. This problem continues until the source SQL Server service is restarted.

Notes
  • You cannot run the DBCC FREESESSIONCACHE statement to resolve this problem.
  • This article discusses one possible cause of this error message. The hotfix that is mentioned in this article will only resolve this problem if your scenario is identical to the scenario that is described here.

↑ Back to the top


Cause

This problem occurs because of a problem in the SQL Server Native Client provider. The handles that the Kerberos connection creates to some connection modules are prematurely released.

↑ Back to the top


Resolution

Service pack information

To resolve this problem, obtain the latest service pack for SQL Server 2005. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
913089 How to obtain the latest service pack for SQL Server 2005

Hotfix information

A supported hotfix is available from Microsoft. However, this hotfix is intended to correct only the problem that is described in this article. Apply this hotfix only to systems that are experiencing this specific problem. This hotfix might receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next software update that contains this hotfix.

If the hotfix is available for download, there is a "Hotfix download available" section at the top of this Knowledge Base article. If this section does not appear, contact Microsoft Customer Service and Support to obtain the hotfix.

Note If additional issues occur or if any troubleshooting is required, you might have to create a separate service request. The usual support costs will apply to additional support questions and issues that do not qualify for this specific hotfix. For a complete list of Microsoft Customer Service and Support telephone numbers or to create a separate service request, visit the following Microsoft Web site: Note The "Hotfix download available" form displays the languages for which the hotfix is available. If you do not see your language, it is because a hotfix is not available for that language.

Prerequisites

You must have SQL Server 2005 Service Pack 1 (SP1) installed to apply this hotfix.

For more information about how to obtain SQL Server 2005 Service Pack 1, click the following article number to view the article in the Microsoft Knowledge Base:
913089 How to obtain the latest service pack for SQL Server 2005

Restart information

You do not have to restart the computer after you apply this hotfix.

Registry information

You do not have to change the registry.

Hotfix file information

This hotfix contains only those files that are required to correct the issues that this article lists. This hotfix may not contain of all the files that you must have to fully update a product to the latest build.

The English version of this hotfix has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time item in Control Panel.
Microsoft SQL Server 2005, Itanium Architecture
File nameFile versionFile sizeDateTimePlatform
Sqlncli.dll2005.90.2193.05,400,40823-Sep-200612:01IA-64
Sqlnclir.rll2005.90.1399.0205,01614-Oct-200521:39Not Applicable
Sqlncli.dll2005.90.2193.02,223,44823-Sep-200608:31x86
Sqlnclir.rll2005.90.1399.0205,52814-Oct-200510:48Not Applicable
Microsoft SQL Server 2005, x64
File nameFile versionFile sizeDateTimePlatform
Sqlncli.dll2005.90.2193.02,855,25623-Sep-200619:54x64
Sqlnclir.rll2005.90.1399.0206,04014-Oct-200521:31Not Applicable
Sqlncli.dll2005.90.2193.02,223,44823-Sep-200608:31x86
Sqlnclir.rll2005.90.1399.0205,52814-Oct-200510:48Not Applicable
Microsoft SQL Server 2005, x86
File nameFile versionFile sizeDateTimePlatform
Sqlncli.dll2005.90.2193.02,223,44823-Sep-200608:31x86
Sqlnclir.rll2005.90.1399.0205,52814-Oct-200510:48Not Applicable

↑ Back to the top


Workaround

To work around this problem, configure the connection between the two SQL Server linked servers to use the Named Pipes protocol instead of the TCP/IP protocol. The Named Pipes protocol does not use Kerberos authentication at the SQL Server level. To configure the connection, follow these steps.

Note In these steps, the source server name is Server1, and the target server name is Server 2.
  1. Make sure that the Named Pipes protocol is enabled on both linked servers.

    To determine whether the Named Pipes protocol is enabled on both linked servers, run the following command at a command prompt on the source computer that is running SQL Server:
    Sqlcmd –E –Snp:Server2
    If this command fails, the Named Pipes protocol is probably not enabled on one or both of the SQL Server linked servers. To enable the Named Pipes protocol, use SQL Server Configuration Manager.
  2. If the command in step 1 succeeds, use one of the following methods:
    • Drop the existing linked server configuration.
    • Create a new linked server configuration that uses a different name and the Named Pipes protocol. On Server 1, execute the following statements to configure a linked server that uses the Named Pipes protocol to connect to Server2:
      EXEC sp_addlinkedserver @server='Server2', @srvproduct='', @provider='SQLNCLI', @datasrc='np:Server2', @provstr='Integrated Security=SSPI'
  3. On Server 1, open SQL Server Management Studio, and then create a new query.
  4. In the query window, run the following linked server query against Server2 to determine whether the Named Pipes protocol is used:
    select net_transport, auth_scheme from Server2.master.sys.dm_exec_connections where session_id=@@spid
    If the Named Pipes protocol is being used, you receive the following result:
    net_transport		auth_scheme
    -------------		---------------
    Named pipe		NTLM

↑ Back to the top


Status

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the"Applies to" section. This problem was first corrected in SQL Server 2005 Service Pack 2.

↑ Back to the top


References

For more information about the naming schema for Microsoft SQL Server updates, click the following article number to view the article in the Microsoft Knowledge Base:
822499 New naming schema for Microsoft SQL Server software update packages
For more information about software update terminology, click the following article number to view the article in the Microsoft Knowledge Base:
824684 Description of the standard terminology that is used to describe Microsoft software updates

↑ Back to the top


Keywords: kbautohotfix, kbsql2005connect, kbhotfixserver, kbexpertiseadvanced, kbqfe, kbprb, kbfix, KB925843

↑ Back to the top

Article Info
Article ID : 925843
Revision : 5
Created on : 11/4/2007
Published on : 11/4/2007
Exists online : False
Views : 388