FIX: DBCC INDEXDEFRAG May Leave a Transaction Open Which Can Cause the Log to Grow Large (282286)



The information in this article applies to:

  • Microsoft SQL Server 2000 (all editions)

This article was previously published under Q282286
BUG #: 351360 (SHILOH_BUGS)

SYMPTOMS

When you run DBCC INDEXDEFRAG on a clustered or nonclustered index, it may sometimes leave a special system transaction open after the process has started the first time on an index being defragmented at a higher root level. Because the transaction is left open for the duration of the entire DBCC INDEXDEFRAG operation, it can cause the transaction log to grow to a large size.

RESOLUTION

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

290211 INF: How to Obtain the Latest SQL Server 2000 Service Pack

WORKAROUND

To work around this problem, start the DBCC INDEXDEFRAG operation, let it run for a short time (such as 5 minutes), and then stop and restart it again.

Because the process commits the work for each defrag page, when the INDEXDEFRAG is interrupted, only the very last transaction will be rolled back; the completed defrag work before the interruption is not affected. The empty system transaction will be rolled back as well, so the log will no longer be held by the open transaction.

STATUS

Microsoft has confirmed that this is a problem in SQL Server 2000. This problem was first corrected in SQL Server 2000 Service Pack 1.

Modification Type:MajorLast Reviewed:10/17/2003
Keywords:kbBug kbfix kbSQLServ2000sp1fix KB282286