I had this weird issue with a Exchange Server environment:
The company had an Exchange Server 2016 DAG and migrated all User Mailboxes to Exchange Online. I then installed a fresh Exchange Server 2019 for Recipient Management and SMTP-Relay.
To use the Exchange Server 2019 Hybrid License, I did not create a Mailbox Database.
I removed all remaining System Mailboxes and Arbitration Mailboxes from the Exchange 2016 Servers. I decomissioned the DAG and uninstalled Exchange from the old Servers.
Error 500#
Soon the company realized, they now get an HTTP Error 500 after authenticating to the Exchange Admin Center (https://exchangeserver2019.example.com/ecp
). So the page still prompted for credentials, but after entering valid credentials -> Error 500.
Investigating#
The Exchange HealthChecker.ps1 did not find any relevant issues.
I also didn’t find any relevant log entries on the system. I forgot how I came to the conclusion, but I suspected the missing System Mailboxes. Maybe it was this Error 5000 - AdminAuditLog Event:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
| Failed to save admin audit log for this cmdlet invocation.
Organization: First Organization
Log content:
Cmdlet Name: Enable-Mailbox
Object Modified: example.com/Users/SystemMailbox{e0dc1c29-89c3-4034-b678-e6c29d823ed9}
Parameter: Identity = SystemMailbox{e0dc1c29-89c3-4034-b678-e6c29d823ed9}
Parameter: Arbitration = True
Caller: example.com/<OUPathToMyAdminAccount>/MyAdminUser
ExternalAccess: False
Succeeded: True
Run Date: 2023-05-16T11:50:20
OriginatingServer: EXCHANGE2019 (15.02.1118.026)
Error:
Exception thrown during AdminLogProvisioningHandler.Validate: Microsoft.Exchange.Data.Storage.ObjectNotFoundException: The discovery mailbox, a hidden default mailbox that is required to search mailboxes, can't be found. It may have been inadvertently deleted. This mailbox must be re-created before you can search mailboxes.
at Microsoft.Exchange.Data.Storage.Infoworker.MailboxSearch.MailboxDataProvider.GetDiscoveryMailbox(IRecipientSession session)
at Microsoft.Exchange.Management.SystemConfigurationTasks.AdminAuditLogHelper.CheckArbitrationMailboxStatus(OrganizationId organizationId, ADUser& user, ExchangePrincipal& principal, Exception& exception)
|
But I think it’s not allowed to host Mailboxes with a Hybrid Server. It’s only allowed for Management and SMTP-Relay - right? I checked the License Terms (Section 3f):
I highlighted the sentence, that I consider relevant.
You may not use the Hybrid edition to host on-premises mailboxes
Okay, not allowed to host on-premises mailboxes. But what counts as a mailbox?
There is even a section at the beginning of the License terms called “Licensing Terminology” - but there is no clarification what it means to “host on-premises mailboxes”. I don’t know, I’m not a lawyer and this is not legal advice. BUT one could claim that creating System-Mailboxes - Mailboxes that are required by the system - is not hosting mailboxes.
By the way you can find the License Terms on the Exchange Install Medium (CU ISO) under <Driveletter>:\Setup\ServerRoles\Common\Eula\en
.
Fix#
I fixed it by recreating a Mailbox Database again and creating the System/Arbitration Mailboxes as described in the Microsoft Documentation here.
1
2
3
4
| # Recreate a Mailbox Database
New-MailboxDatabase -EdbFilePath D:\SystemMailboxDB\DB\SystemMailboxDB.edb -LogFolderPath D:\SystemMailboxDB\LOG\ -Name "System Mailboxes Only"
Restart-Service MSExchangeIS
Mount-Database "System Mailboxes Only"
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
| # See: https://learn.microsoft.com/en-us/exchange/architecture/mailbox-servers/recreate-arbitration-mailboxes?view=exchserver-2019
# Prepare AD / Recreate Mailbox Users
F:\Setup.exe /IAcceptExchangeServerLicenseTerms_DiagnosticDataON /PrepareAD
# Re-enable the System/Arbitration Mailboxes
Enable-Mailbox -Identity "FederatedEmail.4c1f4d8b-8179-4148-93bf-00a95fa1e042" -Arbitration
Enable-Mailbox -Identity "Migration.8f3e7716-2011-43e4-96b1-aba62d229136" -Arbitration
Set-Mailbox -Identity "Migration.8f3e7716-2011-43e4-96b1-aba62d229136" -Arbitration -Management $true -Force
Get-User -ResultSize Unlimited | where {$_.Name -like "SystemMailbox{1f05a927*"} | Enable-Mailbox -Arbitration
Enable-Mailbox -Identity "SystemMailbox{bb558c35-97f1-4cb9-8ff7-d53741dc928c}" -Arbitration
Get-Mailbox "SystemMailbox{bb558c35-97f1-4cb9-8ff7-d53741dc928c}" -Arbitration | Set-Mailbox -Arbitration -UMGrammar $true -OABGen $true -GMGen $true -ClientExtensions $true -MessageTracking $true -PstProvider $true -MaxSendSize 1GB -Force
$OABMBX = Get-Mailbox "SystemMailbox{bb558c35-97f1-4cb9-8ff7-d53741dc928c}" -Arbitration; Set-ADUser $OABMBX.SamAccountName -Add @{"msExchCapabilityIdentifiers"="40","42","43","44","47","51","52","46"}
Enable-Mailbox -Identity "SystemMailbox{e0dc1c29-89c3-4034-b678-e6c29d823ed9}" -Arbitration
Set-Mailbox -Identity "SystemMailbox{e0dc1c29-89c3-4034-b678-e6c29d823ed9}" -Arbitration -UMDataStorage $true -Force
Enable-Mailbox -Identity "SystemMailbox{D0E409A0-AF9B-4720-92FE-AAC869B0D201}" -Arbitration
Enable-Mailbox -Identity "SystemMailbox{2CE34405-31BE-455D-89D7-A7C7DA7A0DAA}" -Arbitration
$ShardMBX = Get-Mailbox -Identity "SystemMailbox{2CE34405-31BE-455D-89D7-A7C7DA7A0DAA}" -Arbitration
Set-Mailbox -Identity "SystemMailbox{2CE34405-31BE-455D-89D7-A7C7DA7A0DAA}" -Arbitration
Set-ADUser $ShardMBX.SamAccountName -Add @{"msExchCapabilityIdentifiers"="66"}
Set-ADUser $ShardMBX.SamAccountName -Add @{"msExchMessageHygieneSCLDeleteThreshold"="9"}
Set-ADUser $ShardMBX.SamAccountName -Add @{"msExchMessageHygieneSCLJunkThreshold"="4"}
Set-ADUser $ShardMBX.SamAccountName -Add @{"msExchMessageHygieneSCLQuarantineThreshold"="9"}
Set-ADUser $ShardMBX.SamAccountName -Add @{"msExchMessageHygieneSCLRejectThreshold"="7"}
# Check result
Set-ADServerSettings -ViewEntireForest $true; Get-Mailbox -Arbitration | Format-Table Name,DisplayName
|