Read time 5 minutes
Exchange Server supports the creation of multiple databases and can host a large number of mailboxes. The size of mailboxes is usually in multiple GBs, and the user can meet all his communication requirements with it. The activities of mailboxes are recorded in the event log of the database. Sometimes, the Exchange database does not show any external error, but they record exceptions in the event log. These exception errors can create fault lines at different levels, and the administrators should resolve them.
It is the Duplicate Key Exception that is recorded in the Exchange Server 2013, and it can occur when you upgrade to Exchange Server 2019 with a cumulative update (CU) 8. The following example is an event log:
‘Event ID: 1309.’
‘Log Name: Application.’
‘Source: ASP.NET 4.0.30319.0’
‘Exception Type: DuplicateKeyException.’
‘Exception message: Cannot add a duplicate key. Use Insert instead
at Microsoft.Exchange.Security.Authentication.FederatedAuthService.CacheReader.AddEntry(String userKey, Int32 userPolicy, ConfigWrapper config).’
The internal environment of the Exchange database is changed due to the cumulative update. Because these exceptions do not give any internal error, users can continue to access mailboxes and use a simple workaround to handle this exception.
When the DuplicateKeyException error occurs, it will ask for the user credentials in Outlook. You can run a cmdlet in the Exchange Management Shell to overcome such a credential window.
‘Set-OrganizationConfig -DefaultAuthenticationPolicy $null’
The cumulative update 9 will fix all the security patches and remove the unwanted exceptions. You can get the set up at the following URL –
After installing the update, you can restart Server and check the event log. Now, there will be no duplicate key exception.
If there are more errors coming up, it shows that there is corruption in the database, and you need to repair corrupt exchange database.
There can be numerous exceptions in the event logs that do not interfere with the mailbox health until their severity is increased. But you cannot expect to run multiple cumulative updates to remove each exception. The DuplicateKeyException occurs due to cumulative update 8. So, an update can also alter the Exchange in a negative way.
You should always have a professional Exchange database repair software available to remove corruption and recover mailboxes. Kernel for Exchange Server Recovery can remove severe corruption from an EDB file and recover its mailboxes. The following method shows that you can save the mailboxes directly to a live Exchange account-
After the completion of the process, you can check the mailboxes in a live Exchange account.
The Jet errors like DuplicateKeyException cannot be fixed using tools like Eseutil. It may further delete data from the database. Kernel for Exchange Server helps to overcome many problems like corruption, large size, slow performance, accidental deletion, etc. Furthermore, the software does not require the log files to start the recovery process. There are multiple destinations for the recovered items, and you can save items in different output files like Outlook PST, live Exchange, Public Folder, and Outlook Profile.