Home » Topic » How to Recover Database In SUSPECT Mode?

How to Recover Database In SUSPECT Mode?

Lincoln Burrows ~ Modified: August 11th, 2015 ~ ~ 1 Minute Reading

Home Forums How to Recover Database In SUSPECT Mode?

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #451 Score: 0
    Lincoln Burrows
    Moderator
    16 pts

    I try to run DBCC CHECKDB with repair option it says “Attempt to BEGIN TRANSACTION in database ‘testdb’ failed because database is in BYPASS RECOVERYmode”

    If I try to reset the status, the database again goes in Suspect state and it seems DBCC commands don’t run on database in Suspect state.

    Does anybody know how to recover the database in this Mode? Is there any other way to repair it?

    #456 Score: 0
    Stephen West
    Moderator
    4 pts

    copy the data out of that database into a new one, vigorously check the logical consistency of the tables then discard the original database.

    #550 Score: 0
    Andrew Jackson
    Moderator
    1 pt

    use this script to recover database from suspect mode

    EXEC sp_resetstatus 'yourDBname';
    ALTER DATABASE yourDBname SET EMERGENCY
    DBCC checkdb('yourDBname')
    ALTER DATABASE yourDBname SET SINGLE_USER WITH ROLLBACK IMMEDIATE
    DBCC CheckDB ('yourDBname', REPAIR_ALLOW_DATA_LOSS)
    ALTER DATABASE yourDBname SET MULTI_USER
Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.