Exchange 2010: Fixing the "Dirty Shutdown State"

In a previous article, I described how to restore a complete Exchange server. However, it can also happen that the Exchange database can no longer be brought online. There are many reasons for this: Full partitions or server crashes. In this article I would like to show measures that can be used to restore the database.

Database in "dirty shutdown state" (soft recovery)

If the database can no longer be made available after an Exchange Server crash, this is often due to a "dirty shutdown". Dirty shutdown means that the database could not be shut down normally and inconsistencies have occurred between the database and the log files as a result. Dirty shutdown does not mean that the database is defective, but before the database can be switched back online, the log files must be compared with the database. The "eseutil" tool can be used to check whether the database is in the dirty shutdown state.

To check the shutdown state of the database, open a command line and change to the directory in which the database is located. Then the command "eseutil /mh "NameDerDantenbank.EDB"" is executed. The output of the command shows a lot of information, the value "State" shows the current status of the database.

Dirty Shutdown State

The Exchange error message when mounting the database is unfortunately somewhat more general:

——————————————————–

Microsoft Exchange error

——————————————————–

The database 'Mailbox Database' could not be provided.

Mailbox Database

Error

Error:

The specified database could not be provided. Specified database: Mailbox Database; Error code: Error during Active Manager operation: Error Error during database action: Error during operation with the following message: MapiExceptionCallFailed: Unable to mount database. (hr=0x80004005, ec=-550)

. [Database: Mailbox Database, Server: EX1.frankysweb.local].

Error during Active Manager operation: Error Error during database action: Error during operation with the following message: MapiExceptionCallFailed: Unable to mount database. (hr=0x80004005, ec=-550)

. [Database: Mailbox Database, Server: EX1.frankysweb.local]

Error during Active Manager operation: Error Error during operation with the following message: MapiExceptionCallFailed: Unable to mount database. (hr=0x80004005, ec=-550)

[Server: EX1.frankysweb.local]

MapiExceptionCallFailed: Unable to mount database. (hr=0x80004005, ec=-550)

Eseutil can also be used to put the database back into the "Clean Shutdown State". Eseutil must be called with the parameter /R followed by the logfile prefix

The /L and /D parameters can also be used to specify alternative paths to log files. In my case, this was not necessary as I was in the corresponding directory. After the logs have been imported into the database, the shutdown state can be checked again with "eseutil /mh"

If everything went well, "Clean Shutdown" is now displayed again and the database can be mounted.

This procedure is also known as soft recovery. If soft recovery is no longer possible, hard recovery remains. However, this results in data loss, as the logs are not restored to the database but are "cut off".

Database in "Dirty Shutdown State" (Hard Recovery)

If the log files are no longer available, it is possible to perform a hard recovery. This restores the database to the clean shutdown state without first restoring the log files to the database. However, this results in a loss of data; all elements that have not yet been saved in the database but have only existed in the logs are lost. This method should therefore only be used as a last resort if all else fails. A corresponding warning is displayed when the command is executed

To perform a hard recovery, Eseutil is started with the parameter /P followed by the database name

"eseutil /p "Name of the database.ESB"

After confirming the command, the warning described above must be confirmed with "OK". When Eseutil is finished, the database can be mounted again.

14 thoughts on “Exchange 2010: Beheben des „Dirty Shutdown State“”

  1. Guter Beitrag – Danke Frank.

    Zur Ergänzung, bei mir war auch die Datenbank im Dirty Shutdown und konnte nur mir /p wieder im CleanShutdown Modus gebracht werden.
    Gemountet konnte sie aber trotzdem nicht werden.
    Nach langem Suchen ist aufgefallen, dass der Laufwerksbuchstabe der Logfiles sich (wie auch immer) geändert hatte.
    Den wieder richtig eingetragen und siehe da – Online und gemountet.
    VG Mike

    Reply
  2. Vielen Dank Franky,

    und wieder einmal hast du mir sehr viel Arbeit erspart. Super Anleitungen Super Erklärungen wenn ich Probleme mit Exchange habe schaue ich zuerst immer hier vorbei :-)

    Reply
  3. Hallo,

    bekomme nach mehreren Versuchen mit eseutil /P
    chk File und Log files verschieben

    die Datenbank nicht zum Laufen – hat jemand eine Idee woran es noch liegen könnten

    lg Lukas

    Reply
  4. Hatte heute den Fall, dass bei einem Kunden mit einem Exchange 2013 Server nach einen Stromausfall die Datenbank im Dirty Shutdown State war.
    Soft Recovery war nicht mehr möglich.

    Hard Recovery funktionierte, allerdings musste ich im Nachgang alle .log und .chk-Dateien der Datenbank verschieben, da sich die Datenbank trotz Clean Shutdown State nach der Reparatur nicht mounten lies.

    Nichtsdestotrotz, wieder mal ein Artikel der das Zeug hat, Leben zu retten :-)

    Reply
  5. Thanks for the useful information about Exchange server dirty shutdown state. It’s really a very big issue faced by the Exchange administrators and most of the time leads to data loss situations. When we were facing this problem, we fixed it with the help of steps and tools as mentioned here: http://rickytechblog.wordpress.com/2012/08/17/tips-to-fix-exchange-dirty-shutdown-state-in-exchange-server/

    I would like to share it with you and all who are encountering similar problem.

    regards,
    Jim

    Reply

Leave a Comment