Exchange Database – Dirty Shutdown

As Exchange Administrator it would be bad day if you have exchagne database in Dirty Shutdown State and you dont have required log files to perform soft recovery. Below link has a steps on how to perform soft recovery if you have al the require log file.

/2009/07/13/disaster-recovery-of-exchange-2007-mailbox-server/

If you dont have the required log files then you have to follow below steps to recover the database

1. Run ESEUTIL /P database_filename.edb (from the BIN folder and repair the edb files)
2. Delete the log and chk files.
3. Run eseutil /d database_filename.edb (Defrag the Database)
4. Run isinteg (isinteg -s servername -fix -test alltests) from the bin folder.
5. Mount the stores

Eseutil and Isinteg would be really long time , depending on the size of the database. Microsoft always recommends to keep the database size less then 100 GB. If you are using CCR environment then it can grow more then 100 GB as you will be multipe copies of the log files for recovery purpose

Exchange 2007 soft recovery of the database

Soft Recovery is the process of remounting the database when the database was shutdown abruptly and when log files and Database files are intact.

 Simple Soft Recovery Process

Mounting of the database is simple soft recovery process which will check the checkpoint file and find the log latest log updated and will update the remaining logs.  If there you no check point it will try to apply oldest log files available. 

 

Advanced Soft Recovery Process (Careful, Make sure that you have the copy of the database and log files before you do this option)

When there is abrupt shutdown and there are chances that Database may go into Dirty shutdown state. When you try to mount the database it may not mount as it is the Dirty Shutdown state. Need to reply the logs manually to bring the database into clean shutdown state.

 

1.  Eseutil /mh “Databasepath” (gets you the details of the clean shutdown or dirty shutdown)

Below snap give the details of the dirty shutdown and it also provide the details of Log Required.

 

 

2. Eseutil /ml “Path of the log file” (get you the header of the logs and there you will find the value of Base name: E00 to use for the applying the logs. This may vary in the log header. Need to make sure that you get the database before you apply the logs

 

3. Move the Check point file the other location .This will cause to replay all the logs available

 

4. Open command prompt and browse to the log file location and run the below mentioned command

 Eseutil /r  /a E00 /d “C:\EDB file path” /S “C:\Log file path” /L “C:\Chckpoint file creation path”

 Make sure that you taken the backup of the log file before you use these options and you make sure that you have all the log file required as per the header of the Database and provide the correct paths. For the simple recovery use below mentioned command

 Eseutil /r E00

 5. On completion it should mount automatically or you can mount the database from Exchange management console. We can checked if Datbase is been changed to clean shutdown form the below mentioned command

 Eseutil /mh “Database path.edb”