Skip to content

Repair a Suspect Database

The step-by-step sequence for attempting to repair a database that has gone into the suspect state.

Published May 17, 2005

When a database ends up in the SUSPECT state after a crash or disk failure, this is the classic repair sequence: reset its status, take it into EMERGENCY mode, run a check to see what is wrong, then - as a last resort - attempt a repair with data loss allowed before bringing it back online. Replace Database_Name with your database and proceed carefully; REPAIR_ALLOW_DATA_LOSS can drop objects.

EXEC sp_resetstatus 'Database_Name';
GO

ALTER DATABASE Database_Name SET EMERGENCY
GO

DBCC checkdb('Database_Name')
GO

ALTER DATABASE Database_Name SET SINGLE_USER WITH ROLLBACK IMMEDIATE
GO

DBCC CheckDB ('Database_Name', REPAIR_ALLOW_DATA_LOSS)
GO

ALTER DATABASE Database_Name SET MULTI_USER
GO
An unhandled error has occurred. Reload 🗙