HiveBrain v1.2.0
Get Started
← Back to all entries
patternsqlMajor

Database 'MyDb' is being recovered. Waiting until recovery is finished

Submitted by: @import:stackexchange-dba··
0
Viewed 0 times
finisheduntilwaitingbeingdatabaserecoveredrecoverymydb

Problem

I got so error:


Database 'MyDb' is being recovered. Waiting until recovery is
finished.

I have had a critical operation at that time.

What is the cause of this situation? And how can it be avoided?

Solution

Crash recovery is running on 'MyDb'. Possible causes:

  • The SQL Server service was restarted manually, due to a crash or a server stop/start.



  • A severe error in the database caused the database to be shut down and recovered.



  • Recovery was initiated deliberately by someone executing a RESTORE WITH RECOVERY.



  • The Auto-Close option is set, causing the database to shut down when the last user exits and run recovery to restart when the next connects.



If recovery is taking a long time to complete and there doesn't appear to be any activity you may need to restore from backups. If you're feeling brave you should start reading everything you can find about repairing/recovering suspect databases.

More information on what happened before the database ended up in this state would make for better answers e.g. what actions you carried out, what errors are in the SQL error log etc.

Context

StackExchange Database Administrators Q#9063, answer score: 24

Revisions (0)

No revisions yet.