FIX: SQLMaint.exe -CkDBRepair Option Does Not Work Correctly

Article translations Article translations
Article ID: 247181 - View products that this article applies to.
This article was previously published under Q247181
This article has been archived. It is offered "as is" and will no longer be updated.
BUG #: 54421 (SQLBUG_70)
Expand all | Collapse all

Symptoms

The Maintenance Plan executes "dbcc checkdb(dbname, REPAIR_FAST) WITH NO_INFOMSGS" if the -CkDBRepair option is specified on the SQLMaint command line.

SQLMaint incorrectly reports the status of the task as successful even though the CHECKDB was never able to run the REPAIR_FAST option.

Cause

For the REPAIR_FAST option to work, the DB needs to be in single user mode. SQLMaint does not put the database in single user mode before running the CHECKDB. Nor does SQLMaint return an error when the DBCC command fails to execute.

Workaround

Add a step in the job to place the database in single user mode before the job runs. SQL Database Maintainance Plans automatically generate jobs. This particular job will be named with the name of the maintainance plan followed by 'DB Maintenance Plan check Integrity'. Edit the job and insert a step to place the database into single user mode before the step that executes the xp_sqlmaint commands.

Status

Microsoft has confirmed this to be a problem in SQL Server 7.0. This problem has been corrected in U.S. Service Pack 2 for Microsoft SQL Server 7.0. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
254561 INF: How to Obtain Service Pack 2 for Microsoft SQL Server 7.0 and Microsoft Data Engine (MSDE) 1.0
For more information, contact your primary support provider.

More information

REPAIR_FAST performs minor, nontime-consuming repair actions such as repairing extra keys in nonclustered indexes. These repairs can be done quickly and without risk of data loss.

Properties

Article ID: 247181 - Last Review: October 26, 2013 - Revision: 3.0
Applies to
  • Microsoft SQL Server 7.0 Standard Edition
Keywords: 
kbnosurvey kbarchive kbbug kbfix KB247181

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com