Exchange Server retrieves all the data from Exchange Server Database files (EDB). Top organizations, MNC’s use Exchange Server to send/ receive emails, share files, calendars, contacts and other data. It allows users to work collectively that enhances the productivity of the organization. Thus, the Exchange Database is of utmost importance and it should be maintained properly. There are free tools available from Microsoft that can repair database and recover user mailbox data.
The Exchange server stores a large amount of information. The Exchange Database Files contain all the data and it stores non-SMTP messages and active messages too. The EDB files have an STM file which has all SMTP messages. The Exchange Database directly works with EDB files. So, to repair Exchange Server Database we must look at corrupt EDB files and other causes that affect it.
How Exchange Database Gets Corrupt
Exchange Server Database deals with a large number of emails and user data. There are number of issues that cause database corruption like
- Virus Attacks
- Sudden power shutdown
- Not closing the database properly
These are different scenarios that cause database corruption
Repair Exchange Database Manually
Microsoft has two utilities Eseutil and Isinteg to repair corrupt database. These tools can be used to repair database errors and removed database inconsistency. Before executing the commands the user should be ready with the following parameters
- Replica of Exchange Database
- Dismount EDB file from Exchange Server
- Available Disk Space
Using the Eseutil command
The Exchange Admin Center could be used for database repair.
- Now go to the directory C: Program Files\ ExchSrvr\ Bin
- Launch the Eseutil.exe and run the command
- Eseutil/r – This command removes the minor errors from the database and repairs it. This is also termed as soft recovery
- Eseutil/p– This command is used to repair severely damaged database files. Users should go for this method after checking all the parameters as it affects a large number of files in Exchange server. The Eseutil/p is also known as hard recovery
- One point to remember before executing the above commands is that the EDB files and STM files should be in the same directory.
Repair EDB and STM files
There is another method by which Exchange Database Files (EDB and STM) can be repaired
- Run the command: Eseutil /P c:exchsrvrmdbdataDB1.EDB /Sd:exchsrvrmdbdataDB1.STM /Te:TEMPREPAIR.EDB
- The above command will repair the DB1 EDB file and STM file in their respective directories.
- Depending upon the size of the EDB file, the time duration in the recovery process may vary.
- After the recovery process gets complete, it will generate a log file with name integ.raw
Defragment Exchange Database
When the Eseutil command is run to repair Exchange Database files it creates index and space distribution tables. The next task is to recreate space trees and indexes. Defragmentation will do this task and compress the size.
- Now Launch the exe tool under –fix –test alltests mode
- This will remove the inconsistency in Exchange Database and defragment it.
So, these are the tools by which you can repair the Exchange Server Database and resolve the EDB errors.