Microsoft KB Archive/923605

From BetaArchive Wiki

Article ID: 923605

Article Last Modified on 11/20/2007



APPLIES TO

  • Microsoft SQL Server 2005 Standard Edition
  • Microsoft SQL Server 2005 Developer Edition
  • Microsoft SQL Server 2005 Enterprise Edition
  • Microsoft SQL Server 2005 Standard X64 Edition
  • Microsoft SQL Server 2005 Standard Edition for Itanium-based Systems
  • Microsoft SQL Server 2005 Enterprise X64 Edition
  • Microsoft SQL Server 2005 Enterprise Edition for Itanium-based Systems



Bug #: 1124 (SQL Hotfix)


Notice

Microsoft distributes Microsoft SQL Server 2005 fixes as one downloadable file. Because the fixes are cumulative, each new release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2005 fix release.

This article describes the following about this hotfix release:

  • The issues that are fixed by this hotfix package
  • The prerequisites for installing the hotfix package
  • Information about whether you must restart the computer after you install 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
  • The files that are contained in the hotfix package


SYMPTOMS

When you run a query on a computer that is running SQL Server 2005 and has multiple processors, a deadlock occurs, and the query never finishes. Additionally, error messages that resemble the following are logged in the SQL Server 2005 Errorlog file:

2006-06-23 18:40:57.24 spid51 Drop Temp Obj: Failed, serializing drops...
2006-06-23 18:41:07.24 spid4s Deadlock encountered .... Printing deadlock information
2006-06-23 18:41:07.24 spid4s Wait-for graph
2006-06-23 18:41:07.24 spid4s
2006-06-23 18:41:07.24 spid4s Node:1
2006-06-23 18:41:07.24 spid4s OBJECT: 2:2103730597:0 CleanCnt:3 Mode:Sch-S Flags: 0x0
2006-06-23 18:41:07.24 spid4s Grant List 0:
2006-06-23 18:41:07.24 spid4s Owner:0x00000000FB68B780 Mode: Sch-S Flg:0x0 Ref:16 Life:00000000 SPID:51 ECID:0 XactLockInfo: 0x00000000D6D1AD78
2006-06-23 18:41:07.24 spid4s SPID: 51 ECID: 0 Statement Type: EXECUTE Line #: 123
2006-06-23 18:41:07.24 spid4s Input Buf: Language Event: <SQL STATEMENT>
2006-06-23 18:41:07.24 spid4s Requested By:
2006-06-23 18:41:07.24 spid4s ResType:LockOwner Stype:'OR'Xdes:0x00000000D6D1B9F0 Mode: Sch-M SPID:51 BatchID:0 ECID:0 TaskProxy:(0x00000000B16BA570) Value:0x801807c0 Cost:(N/A)
2006-06-23 18:41:07.24 spid4s Deadlock monitor failed to resolve this deadlock. Server may require restart to recover from this condition

2006-06-23 18:41:07.24 spid4s Using 'dbghelp.dll' version '4.0.5'
2006-06-23 18:41:07.24 spid18s deadlock-list
2006-06-23 18:41:07.24 spid18s deadlock victim=process0
2006-06-23 18:41:07.24 spid18s process-list
2006-06-23 18:41:07.24 spid18s process id=processea4718 waitresource=OBJECT: 2:2103730597:0 waittime=10000 ownerId=184497 transactionname=droptemp lasttranstarted=2006-06-23T18:40:57.243 XDES=0xd6d1b9f0 lockMode=Sch-M schedulerid=2 kpid=808 status=suspended spid=51 sbid=0 ecid=0 priority=0 transcount=1 lastbatchstarted=2006-06-23T18:38:46.930 lastbatchcompleted=2006-06-23T18:38:46.930 clientapp=SQL Query Analyzer hostname=FOO hostpid=1234 loginname=DOMAIN\USER isolationlevel=read committed (2) xactid=172623 currentdb=11 lockTimeout=4294967295 clientoption1=673187936 clientoption2=128056
2006-06-23 18:41:07.24 spid18s executionStack
2006-06-23 18:41:07.24 spid18s frame procname=database.dbo.storedprocedure line=123 stmtstart=43720 stmtend=43986 sqlhandle=0x03000b003589375d7cb53201e99700000100000000000000
2006-06-23 18:41:07.24 spid18s <SQL STATEMENT>
2006-06-23 18:41:07.24 spid18s frame procname=adhoc line=2 stmtstart=34 stmtend=116 sqlhandle=0x01000b009d96c716f07b76ab000000000000000000000000
2006-06-23 18:41:07.24 spid18s <SQL STATEMENT>
2006-06-23 18:41:07.24 spid18s inputbuf
2006-06-23 18:41:07.24 spid18s <SQL STATEMENT>
2006-06-23 18:41:07.24 spid18s resource-list
2006-06-23 18:41:07.24 spid18s objectlock lockPartition=0 objid=2103730597 subresource=FULL dbid=2 objectname=tempdb.dbo.#7D6461A5 id=lockbb29f600 mode=Sch-S associatedObjectId=2103730597
2006-06-23 18:41:07.24 spid18s owner-list
2006-06-23 18:41:07.24 spid18s owner id=processea4718 mode=Sch-S
2006-06-23 18:41:07.24 spid18s waiter-list
2006-06-23 18:41:07.24 spid18s waiter id=processea4718 mode=Sch-M requestType=wait
2006-06-23 18:41:07.24 spid4s **Dump thread - spid = 4, PSS = 0x000000008011EB40, EC = 0x000000008011EB50
2006-06-23 18:41:07.24 spid4s ***Stack Dump being sent to c:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\LOG\SQLDump0001.txt
2006-06-23 18:41:07.24 spid4s *
2006-06-23 18:41:07.24 spid4s * BEGIN STACK DUMP:
2006-06-23 18:41:07.24 spid4s * 08/01/07 15:54:00 spid 4
2006-06-23 18:41:07.24 spid4s *
2006-06-23 18:41:07.24 spid4s * Unresolved deadlock **************************************************

This problem occurs if table variables are used in a transaction.

RESOLUTION

A supported hotfix is now 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 service pack that contains this hotfix.

To resolve this problem, submit a request to Microsoft Online Customer Services to obtain the hotfix. To submit an online request to obtain the hotfix, visit the following Microsoft Web site:

Note If additional issues occur or 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. To create a separate service request, visit the following Microsoft Web site:

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.

SQL Server 2005 hotfix, 32-bit
File name File version File size Date Time Platform
Logread.exe 2005.90.2181.0 398,112 15-Aug-2006 08:28 x86
Microsoft.analysisservices.adomdclient.dll 9.0.2181.0 543,520 15-Aug-2006 08:28 x86
Microsoft.analysisservices.deploymentengine.dll 9.0.2181.0 138,016 15-Aug-2006 08:26 x86
Microsoft.analysisservices.dll 9.0.2181.0 1,215,264 15-Aug-2006 08:26 x86
Microsoft.sqlserver.mgdsqldumper.dll 2005.90.2181.0 75,552 15-Aug-2006 08:25 x86
Microsoft.sqlserver.sqlenum.dll 9.0.2181.0 908,064 15-Aug-2006 08:26 x86
Msgprox.dll 2005.90.2181.0 197,920 15-Aug-2006 08:28 x86
Msmdlocal.dll 9.0.2181.0 15,703,840 15-Aug-2006 08:27 x86
Msmdredir.dll 9.0.2181.0 3,968,800 15-Aug-2006 08:27 x86
Mssqlsystemresource.ldf Not Applicable 524,288 14-Aug-2006 22:49 Not Applicable
Mssqlsystemresource.mdf Not Applicable 39,911,424 14-Aug-2006 22:49 Not Applicable
Replprov.dll 2005.90.2181.0 547,616 15-Aug-2006 08:29 x86
Replrec.dll 2005.90.2181.0 782,112 15-Aug-2006 08:26 x86
Sqlaccess.dll 2005.90.2181.0 347,936 15-Aug-2006 08:28 x86
Sqlagent90.exe 2005.90.2181.0 319,264 15-Aug-2006 08:27 x86
Sqlservr.exe 2005.90.2181.0 28,951,384 15-Aug-2006 08:27 x86
Sysdbupg.sql Not Applicable 192,346 19-Jul-2006 17:02 Not Applicable
Xpstar90.dll 2005.90.2181.0 292,640 15-Aug-2006 08:31 x86
Xpstar90.rll 2005.90.2181.0 152,864 15-Aug-2006 08:27 x86
SQL Server 2005 hotfix, 64-bit
File name File version File size Date Time Platform
Logread.exe 2005.90.2181.0 522,528 15-Aug-2006 08:20 x64
Microsoft.analysisservices.adomdclient.dll 9.0.2181.0 543,520 15-Aug-2006 08:20 x86
Microsoft.analysisservices.adomdclient.dll 9.0.2181.0 543,520 15-Aug-2006 08:28 x86
Microsoft.analysisservices.deploymentengine.dll 9.0.2181.0 138,016 15-Aug-2006 08:26 x86
Microsoft.analysisservices.dll 9.0.2181.0 1,215,264 15-Aug-2006 08:26 x86
Microsoft.sqlserver.mgdsqldumper.dll 2005.90.2181.0 91,424 15-Aug-2006 08:19 x64
Microsoft.sqlserver.mgdsqldumper.dll 2005.90.2181.0 75,552 15-Aug-2006 08:25 x86
Microsoft.sqlserver.sqlenum.dll 9.0.2181.0 875,296 15-Aug-2006 08:21 x86
Msgprox.dll 2005.90.2181.0 259,360 15-Aug-2006 08:20 x64
Msmdlocal.dll 9.0.2181.0 15,703,840 15-Aug-2006 08:27 x86
Msmdredir.dll 9.0.2181.0 3,968,800 15-Aug-2006 08:27 x86
Mssqlsystemresource.ldf Not Applicable 524,288 14-Aug-2006 22:49 Not Applicable
Mssqlsystemresource.mdf Not Applicable 39,911,424 14-Aug-2006 22:49 Not Applicable
Replprov.dll 2005.90.2181.0 745,248 15-Aug-2006 08:21 x64
Replrec.dll 2005.90.2181.0 1,008,416 15-Aug-2006 08:19 x64
Sqlaccess.dll 2005.90.2181.0 355,104 15-Aug-2006 08:20 x86
Sqlagent90.exe 2005.90.2181.0 390,944 15-Aug-2006 08:20 x64
Sqlservr.exe 2005.90.2181.0 39,327,520 15-Aug-2006 08:20 x64
Sysdbupg.sql Not Applicable 192,346 19-Jul-2006 17:02 Not Applicable
Xpstar90.dll 2005.90.2181.0 540,448 15-Aug-2006 08:20 x64
Xpstar90.rll 2005.90.2181.0 153,376 15-Aug-2006 08:19 x64
SQL Server 2005 hotfix, 64-bit for Itanium processors
File name File version File size Date Time Platform
Logread.exe 2005.90.2181.0 1,095,456 15-Aug-2006 08:20 IA-64
Microsoft.analysisservices.adomdclient.dll 9.0.2181.0 543,520 15-Aug-2006 08:19 x86
Microsoft.analysisservices.adomdclient.dll 9.0.2181.0 543,520 15-Aug-2006 08:28 x86
Microsoft.analysisservices.deploymentengine.dll 9.0.2181.0 138,016 15-Aug-2006 08:26 x86
Microsoft.analysisservices.dll 9.0.2181.0 1,215,264 15-Aug-2006 08:26 x86
Microsoft.sqlserver.mgdsqldumper.dll 2005.90.2181.0 163,104 15-Aug-2006 08:18 IA-64
Microsoft.sqlserver.mgdsqldumper.dll 2005.90.2181.0 75,552 15-Aug-2006 08:25 x86
Microsoft.sqlserver.sqlenum.dll 9.0.2181.0 875,296 15-Aug-2006 08:20 x86
Msgprox.dll 2005.90.2181.0 542,496 15-Aug-2006 08:19 IA-64
Msmdlocal.dll 9.0.2181.0 48,837,408 15-Aug-2006 08:21 IA-64
Msmdredir.dll 9.0.2181.0 6,155,040 15-Aug-2006 08:21 IA-64
Mssqlsystemresource.ldf Not Applicable 524,288 14-Aug-2006 22:49 Not Applicable
Mssqlsystemresource.mdf Not Applicable 39,911,424 14-Aug-2006 22:49 Not Applicable
Replprov.dll 2005.90.2181.0 1,617,184 15-Aug-2006 08:21 IA-64
Replrec.dll 2005.90.2181.0 2,141,472 15-Aug-2006 08:21 IA-64
Sqlaccess.dll 2005.90.2181.0 349,472 15-Aug-2006 08:19 x86
Sqlagent90.exe 2005.90.2181.0 1,143,584 15-Aug-2006 08:20 IA-64
Sqlservr.exe 2005.90.2181.0 72,196,896 15-Aug-2006 08:21 IA-64
Sysdbupg.sql Not Applicable 192,346 19-Jul-2006 17:02 Not Applicable
Xpstar90.dll 2005.90.2181.0 950,560 15-Aug-2006 08:22 IA-64
Xpstar90.rll 2005.90.2181.0 152,352 15-Aug-2006 08:18 IA-64


WORKAROUND

To work around this problem, use one of the following methods:

  • Restart the SQL Server service to resolve the deadlock.
  • When this problem occurs, set the max degree of parallelism option to 1.


STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.

MORE INFORMATION

Call stack information

ChildEBP RetAddr  
05c3e720 7d4d8c46 ntdll!NtWaitForSingleObject+0x15
05c3e790 7d4d8bb5 kernel32!WaitForSingleObjectEx+0xac
05c3e7a4 02441816 kernel32!WaitForSingleObject+0x12
05c3e824 024413f2 sqlservr!CDmpDump::DumpInternal+0x311
05c3e860 02194394 sqlservr!CDmpDump::Dump+0x59
05c3e920 0218b8e2 sqlservr!CImageHelper::DoMiniDump+0x3d2
05c3f6d8 020e7fea sqlservr!stackTrace+0x6c8
05c3f77c 014683c0 sqlservr!DeadlockMonitor::ReportUnresolvable+0x286
05c3f7e0 01098d63 sqlservr!DeadlockMonitor::SearchAndResolve+0x219
05c3f834 01081d87 sqlservr!DeadlockMonitor::SearchTaskAndResolve+0xb3
05c3f8dc 01081dd5 sqlservr!DeadlockMonitor::WorkLoop+0x82a
05c3f960 02132481 sqlservr!lockMonitor+0xbf
05c3fd54 01006a96 sqlservr!lockMonitorThread+0x314
05c3fdc4 01006bbc sqlservr!SOS_Task::Param::Execute+0xe2
05c3fdf8 01006dab sqlservr!SOS_Scheduler::RunTask+0xb9
05c3fe38 01447562 sqlservr!SOS_Scheduler::ProcessTasks+0x141
05c3fea0 0144859b sqlservr!SchedulerManager::WorkerEntryPoint+0x1a8
05c3feb8 0144789a sqlservr!SystemThread::RunWorker+0x7f
05c3ff10 01447720 sqlservr!SystemThreadDispatcher::ProcessWorker+0x225
05c3ff78 781329aa sqlservr!SchedulerManager::ThreadEntryPoint+0x143
05c3ffb0 78132a36 msvcr80!_callthreadstartex+0x1b
05c3ffb8 7d4e0729 msvcr80!_threadstartex+0x66
05c3ffec 00000000 kernel32!BaseThreadStart+0x34

ChildEBP RetAddr  
0886e3b4 7d4d8c46 ntdll!NtWaitForSingleObject+0x15
0886e424 7d4d8bb5 kernel32!WaitForSingleObjectEx+0xac
0886e438 010032d2 kernel32!WaitForSingleObject+0x12
0886e5b0 010026f2 sqlservr!SOS_Scheduler::SwitchContext+0x232
0886e5c8 01001e93 sqlservr!SOS_Scheduler::SuspendNonPreemptive+0xb9
0886e5e0 01002b95 sqlservr!SOS_Scheduler::Suspend+0x2e
0886e604 01058926 sqlservr!SOS_Event::Wait+0x12a
0886e640 01058a3d sqlservr!LockOwner::Sleep+0x13e
0886e6e4 0100cc9f sqlservr!lck_lockInternal+0x990
0886e790 010209b0 sqlservr!RowsetLockCache::GetTableLock+0x31b
0886e7dc 011acb90 sqlservr!MDL::FLockObjectId+0x6c
0886e820 0124db73 sqlservr!CMEDCatalogObject::GetCachedObjectById+0x9b
0886e858 0197a4e1 sqlservr!CMEDProxyDatabase::GetObjectByObjectId+0x78
0886e90c 01c3a3fd sqlservr!FDropTempWithNolog+0x142
0886e934 019e823f sqlservr!TmpObject::Release+0x67
0886e950 019e842a sqlservr!CTableVariableManager::DropNormalTablesInCurScope+0x5c
0886e954 014ac4d3 sqlservr!CTableVariableManager::PopSqlScope+0x7
0886e960 0137c579 sqlservr!CExecLevel::PopSqlScopeInternal+0x69
0886e970 013676d1 sqlservr!CSQLSource::PopSqlScope+0x28
0886e9a0 013674c1 sqlservr!CStmtExecProc::XretLocalExec+0x2d6
0886efa4 01367356 sqlservr!CStmtExecProc::XretExecExecute+0x552
0886efc4 010251bc sqlservr!CXStmtExec::XretExecute+0x23
0886f058 01025741 sqlservr!CMsqlExecContext::ExecuteStmts<1,1>+0x360
0886f104 01023e34 sqlservr!CMsqlExecContext::FExecute+0x55b
0886f1c4 0136764a sqlservr!CSQLSource::Execute+0x73b
0886f200 013674c1 sqlservr!CStmtExecProc::XretLocalExec+0x1f6
0886f804 01367356 sqlservr!CStmtExecProc::XretExecExecute+0x552
0886f824 010251bc sqlservr!CXStmtExec::XretExecute+0x23
0886f8b8 01025741 sqlservr!CMsqlExecContext::ExecuteStmts<1,1>+0x360
0886f964 01023e34 sqlservr!CMsqlExecContext::FExecute+0x55b
0886fa24 01041dd5 sqlservr!CSQLSource::Execute+0x73b
0886fb9c 0103dfd4 sqlservr!process_request+0x2e3
0886fd54 01006a96 sqlservr!process_commands+0x2e0
0886fdc4 01006bbc sqlservr!SOS_Task::Param::Execute+0xe2
0886fdf8 01006dab sqlservr!SOS_Scheduler::RunTask+0xb9
0886fe38 01447562 sqlservr!SOS_Scheduler::ProcessTasks+0x141
0886fea0 0144859b sqlservr!SchedulerManager::WorkerEntryPoint+0x1a8
0886feb8 0144789a sqlservr!SystemThread::RunWorker+0x7f
0886ff10 01447720 sqlservr!SystemThreadDispatcher::ProcessWorker+0x225
0886ff78 781329aa sqlservr!SchedulerManager::ThreadEntryPoint+0x143
0886ffb0 78132a36 msvcr80!_callthreadstartex+0x1b
0886ffb8 7d4e0729 msvcr80!_threadstartex+0x66
0886ffec 00000000 kernel32!BaseThreadStart+0x34
s

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



Additional query words: Unresolved deadlock

Keywords: kbtshoot kbfix kbqfe kbpubtypekc kbexpertiseadvanced kbhotfixserver kbsql2005engine KB923605