Problems can occur on an Exchange 2019 server if a database is larger than 1 TB. On an Exchange 2019 Standard Server, the maximum database size is 1 TB; if the database is larger, there are problems with failover within the DAG. Databases larger than 1 TB can also be mounted on an Exchange Standard Server. The following error message from the ExchangeStoreDB source is then logged in the event log:
Source: ExchangeStoreDB
Event ID: 171
Message:
At ‚16.04.2023 19:38:25‘ database copy ‚DBNAME‘ on this server exceeded the configured maximum database size and service recovery was not attempted. Please increase the value of this registry key on the server hosting the active database copy before attempting to mount this database. For more details about the failure, consult the Event log on the server for other storage and „MSExchangeIS“ events.
Exchange Server 2019 Enterprise Edition has no such limit. Fortunately, you do not necessarily have to switch to the Enterprise Edition if a database becomes larger. The limit can be easily adjusted in the registry.
To increase the maximum database size, you must first display the GUID of the database:
Get-MailboxDatabase DATENBANKNAME | select name,guid
The following path must now be searched for in the registry:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\MSExchangeIS\SERVERNAME\Private-DATENBANKGUID
Unter diesem Pfad lässt sich jetzt ein neues DWORD mit dem Namen „Database Size Limit in GB“ und dem gewünschten neuen Limit als Dezimalwert anlegen. In diesem Beispiel sind es 2 TB:
After the limit has been adjusted, the database can be mounted again with the following command:
Mount-Database DBNAME -Force
If you have several databases and several Exchange servers, you can also make your work a little easier with a small PowerShell script:
#New max database size in GB:
$NewDBMaxSize = 2048
$DBGUIDs = Get-ExchangeServer $env:computername | Get-MailboxDatabase | select guid
foreach ($DBGUID in $DBGUIDs) {
$RegPath = "HKLM:\SYSTEM\CurrentControlSet\Services\MSExchangeIS\"
$DatabaseRegPath = "HKLM:\SYSTEM\CurrentControlSet\Services\MSExchangeIS\" + $env:computername + "\Private-" + $DBGUID.Guid
New-ItemProperty -Path $DatabaseRegPath -Name "Database Size Limit in GB" -Value $NewDBMaxSize -PropertyType DWORD -Force | Out-Null
}
The script determines the GUIDs of the databases on the server on which it is executed and enters the new limit ($NewDBMaxSize) in the registry. The script must be executed in an Exchange Management Shell with administrative rights. These limits also apply to Exchange Server 2016 in the Standard Edition. The script is also available on GitHub: