Overview – With Exchange Server 2010, a tool named ESEutil (Extensible Storage Engine utility) is available for DBAs that is operated through command-prompt. In this segment, we will talk about ESEutil in detail and its switches. Also, a discussion on how to defragment or repair Exchange 2010 database using ESEutil will be done.
Exchange 2010 database is made up of three important constituents: The Database (.edb) file, the Transaction LOG (.log) file, and the Checkpoint (.chk) file.
The JET Blue (ESE) database engine of Exchange Server works on data saved in "Pages". Particularly, for Exchange 2010 edition, each page is of 32 KB and multiple pages of this kind store data in EDB file (which is a Binary-Tree). When a transaction occurs, for example deletion of a folder, sending an email, adding a contact, it is first written into the memory, then to the log files and finally to the database. This technique is known as Write-Head Logging.
When a log file is filled with maximum number of transactions, a new log file gets automatically created with a name that continues the previous series. For example: the first log file was E00.log (where E00 is the prefix) and once it is filled, new series get generated with changes in prefix like E01.log, E02.log and so on. Log file numbering is done in hexadecimal format.
An EDB is an open file and the uncommitted transactions still exist in the LOG file. When DB is mounted on Server, the uncommitted transactions will be written to the database. When this happens perfectly, it means the database is detached from the LOG files. Now if this database is dismounted, the checkpoint file will be updated and DB will be in Consistent state (also known as Clean Shutdown State).
Now, in any situation when Exchange Server is not shutdown properly (example Server crash or unexpected power-off), the database is left inconsistent (Dirty Shut Down State). This is because the database was still attached to the LOG files for updation but the process could not get completed due to Server being shutdown unexpectedly. In such cases, when the Server starts again, it performs Soft Recovery of database where log files are replayed using the Checkpoint file. In 90 percent of the cases, this problem is resolved automatically, and for rest 10 percent, there is ESEutil for help.
Also, there is possibility that some pages of the EDB file get corrupt in the disk or the device controller. Such cases result in error -1018 JET_errReadVerifyFailure. ESEutil helps to deal with file-system (page) level corruption of Exchange database.
ESEutil is a command-line utility available under Bin Directory that helps to perform number of operations on database like repair, offline defragmentation, integrity check, checksum test etc. This utility works on dismounted database and is available automatically when Exchange Server is installed.
Exchange database is a B-Tree structure that consists of pages. Now these pages can itself hold data in it or can point to other pages in the database. When ESEutil /p switch is run against the database for repair process, it looks after the table and records of the EDB file and if any corrupt pages are encountered, it deletes them. If a leaf node of the B-tree is corrupt, data loss will happen and if the internal node of the tree is corrupt, then structure of the database will be dis-balanced.
Meanwhile, the repair process with ESEutil is divided into three sections:
Now, to repair Exchange 2010 database, use the syntax:
Once this command is run, the repair database will be in this state:
Now, you could notice the free space in database after running ESEutil /p command. To rebuild the DB by removing white space from it, perform offline defragmentation using following syntax:
Now, the state of DB would be like:
Defragmentation will disturb the index of B-tree and thus to do correction in database at application level, the solution is to run ISInteg utility. The syntax to be followed is:
After all this processing, the database will be ready to mount on Server:
Things to Remember:
The command-line solution to repair Exchange 2010 database using ESEutil can be availed in Graphical User Interface through Exchange Recovery software. This tool will recover EDB file data to PST, MSG, EML, HTML, PDF & MBOX file. Also, mailboxes from EDB file can be exported to different Exchange Server.
Exchange and Naive users use the Exchange Recovery tool to recover highly corrupted .edb file without any data loss. All this can be done by using the Advance scan option, which also recovers purged mailboxes or data items from the loaded Exchange Database file. The software provides two scan mode i.e. Quick and Advance scan. Where a quick scan is used to remove the minimum corruption from the EDB file.
Users also preview the repaired Exchange Mailboxes and data items such as journals, notes, tasks, emails, calendars, contacts. Also, they can selectively export the recovered and healthy EDB file, mailbox, or data items into various file formats and Live Exchange Server, Office 365.
Features Of Professional Software
Step 1: Download, Install & Run Exchange Recovery tool
Step 2: Click on Add file button and Load offline EDB file
Step 3: Click on the Advance scan to repair Exchange 2010 database from corruption. Then click on Add button
Step 4: Preview the repaired .edb file, mailboxes or data items and click on Export
Step 5: Select the Exchange Mailbox from the folder list. Choose the Export Option
Step 6: Click on Browse to set the target file location and click export
Step 7: Finally, the selected Exchange mailbox is exported to the chosen export option
Technical and Non-technical users can use this utility. It provides the graphical interface, so there is no need to insert and execute any command. The software is the best alternative ESEUTIL which helps users to repair Exchange 2010 database.