How to Fix Exchange Dirty Shutdown Error

There are various reasons that may lead to the Dirty Shutdown error. Follow the below-mentioned steps to troubleshoot and resolve dirty shutdown error in exchange server.

Exchange Dirty Shutdown Error

 Reasons for Dirty Shutdown in Exchange Server

The Dirty Shutdown error occurs when the database is corrupt, unhealthy, or inconsistent. The primary reason for the dirty shutdown error is inconsistent or missing  log files. There are various other reasons that may lead to the Dirty Shutdown error. Some of them are:

  • Exchange Server crash
  • Sudden power failure or abrupt termination
  • Malware attack on the server
  • Exchange Server storage issues
  • Deleted log files 
  • Hard disk failure where the Exchange server is installed
  • Outdated or faulty Exchange Server
  • Physical and logical corruption of transaction log files
  • Transaction log files are not committed to the Exchange database

When the Exchange Server enters the Dirty Shutdown state, the users cannot access their mailboxes. Also, the database will not mount and transaction log files cannot be committed to the database. If you try to mount the database in this state, you may encounter the below-mentioned errors:

  • Failed to mount database
  • The database was not shutdown cleanly
  • The operation terminated with error-550 (JET_errDatabaseDirtyShutdown, Database was not shut down cleanly. Recovery must first be run to properly complete the database
  • Operation failed with the message: MapiExceptionDatabaseError


Steps to Fix Dirty Shutdown Error in Exchange 

To fix this error, you can use ESEUtil - an inbuilt command-line-based Exchange database recovery tool. Follow the below steps to fix the Exchange Dirty Shutdown error using the ESEUtil tool:

  • Step 1: Take a backup of all the database files (.stm and .edb) and transaction log files at a different location.
  • Step 2: Before initiating the Exchange database recovery, ensure there is sufficient empty space on the disk. 
  • Step 3: Open the Command Prompt and run as administrator. Execute the below-mentioned command to check the state of the database. 

eseutil /mh <database file name>

It will display the current state of the database as Dirty Shutdown and display the uncommitted log prefix. Take note of the uncommitted logs.

  • Step 4: Check the health of the transaction logs. Execute the following command to check the health of log files. 

eseutil /ml <log path> 

For example: eseutil /ml "M:\mbx01\logs

If the output displays the message, “No damaged files were found”, then move to the next step.

  • Step 5: Perform the soft recovery by running the below command. 

eseutil /r E03 /l M:\ExDb\logs /d M:\ExDb\DB01

Once the command is executed, check if the output displays “Repaired output”. If it is repaired, check the state of the database again using eseutil /MH command. 

  • Step 6: If the soft recovery does not work, you need to perform the hard recovery using the following command.

Eseutil /p <database path> 

Note: Hard recovery results in data loss as it deletes the data which is deemed as corrupted. Also, there is no guarantee that the database will mount after this operation.

  • Step 7: Defragment the database using the below command.

          Eseutil /d 

  • Step 8: Check the consistency of the database with the eseutil /mh command. It should display the status as Clean Shutdown.

  • Step 9: Now, you can mount the database using the below command.

Mount-Database –Identity <dbname> –Confirm:$False


Alternative Approach to Recover Exchange Server Database 

If the soft or hard recovery operation does not work, then an easier and more automatic solution is to use Exchange server recovery software like Stellar Repair for Exchange.  This software can help you scan and repair the corrupted Exchange database (EDB) file. It can recover all the items from an EDB file, including notes, tasks, emails, contacts, calendars, and journal records, and save them in PST files, without any risk of data loss. It can also export the Exchange mailboxes from a dismounted or corrupted database to a live Exchange Server or Microsoft 365 tenant in a few clicks. This Exchange recovery tool supports Microsoft Exchange 2019, 2016, 2013, 2010, 2007, 2003, 2000, and 5.5 versions.


Conclusion

The Dirty Shutdown error in the Exchange Server can occur due to multiple reasons and lead to disrupted mailbox connectivity, inaccessibility, and offline database. Therefore, it is crucial to resolve this error and restore user mailbox connectivity. You can use the ESEUtil utility in Microsoft Exchange to fix this error. However, it requires a lot of time to repair the Exchange database using this utility. And at the same time, the users cannot access their mailboxes and send or receive the emails during the recovery process. It can also lead to loss of data and extended server downtime. 


Alternatively, you can use an Exchange repair software, like Stellar Repair for Exchange to repair the damaged Exchange database. This software can help you repair the database and extract the mailboxes in usable formats, such as PST, HTML, MSG, EML, RTF, and PDF. It helps you to recover the database in minimum time and without any data loss.

The Scientific World

The Scientific World is a Scientific and Technical Information Network that provides readers with informative & educational blogs and articles. Site Admin: Mahtab Alam Quddusi - Blogger, writer and digital publisher.

Previous Post Next Post

نموذج الاتصال