Before deploying or upgrading Microsoft Exchange Server—whether applying a new Cumulative Update (CU) or upgrading to Exchange Server Subscription Edition (SE) or Exchange Server 2019—the first and most critical prerequisite is preparing Active Directory.
Running Setup.exe /PrepareSchema, Setup.exe /PrepareAD, and Setup.exe /PrepareAllDomains modifies directory classes, attributes, and security containers. If setup fails halfway through, or if domain controllers have not finished replicating schema changes across sites, running subsequent Exchange setup wizards will fail with blocking error messages.
In this updated enterprise reference, we provide the complete Active Directory Schema Version Matrix spanning Exchange Server SE, 2019, 2016, and legacy releases, explain how to inspect the three critical Active Directory naming contexts, and share an automated PowerShell script to validate schema readiness in seconds.
The Three Active Directory Schema Verification Points
To confirm that Active Directory has been completely and successfully prepared for an Exchange update, administrators must verify three distinct attributes across three Active Directory naming contexts:
- Schema Container (
rangeUpper): Located in the Schema naming context onCN=ms-Exch-Schema-Version-Pt. This value updates duringSetup.exe /PrepareSchema. - Exchange Organization Container (
objectVersion): Located in the Configuration naming context underCN=<OrganizationName>,CN=Microsoft Exchange,CN=Services. This value updates duringSetup.exe /PrepareAD. - Microsoft Exchange System Objects (MESO) Container (
objectVersion): Located in each domain naming context underCN=Microsoft Exchange System Objects,DC=<Domain>. This value updates duringSetup.exe /PrepareDomainor/PrepareAllDomains.
Active Directory Schema Version Reference Matrix
The following reference table maps each version of Microsoft Exchange Server to its corresponding rangeUpper, Forest objectVersion, and Domain objectVersion:
| Exchange Server Version | Schema (rangeUpper) | Forest (objectVersion) | Domain (objectVersion) |
|---|---|---|---|
| Exchange Server SE RTM / CU1 | 17000 / 17001 | 16230+ | 13238 |
| Exchange Server 2019 CU14 (2024 H1) | 15337 | 16223 | 13236 |
| Exchange Server 2019 CU13 | 15337 | 16223 | 13236 |
| Exchange Server 2019 CU12 | 15337 | 16223 | 13236 |
| Exchange Server 2019 CU11 | 15335 | 16223 | 13236 |
| Exchange Server 2019 CU10 | 15335 | 16222 | 13236 |
| Exchange Server 2019 CU9 | 15335 | 16221 | 13236 |
| Exchange Server 2019 CU8 | 15335 | 16220 | 13236 |
| Exchange Server 2019 RTM | 15332 | 16213 | 13236 |
| Exchange Server 2016 CU23 | 15337 | 16223 | 13236 |
| Exchange Server 2016 CU22 | 15335 | 16223 | 13236 |
| Exchange Server 2016 CU1 | 15332 | 16134 | 13236 |
| Exchange Server 2016 RTM | 15317 | 16134 | 13236 |
| Exchange Server 2013 CU23 | 15312 | 15449 | 13236 |
| Exchange Server 2010 SP3 | 14734 | 14322 | 13040 |
| Exchange Server 2007 SP3 | 14625 | 11222 | 11221 |
| Exchange Server 2003 SP2 | 6870 | 6903 | 6936 |
Automated PowerShell Script: Verifying Schema Across AD Naming Contexts
Instead of manually navigating through adsiedit.msc, run this PowerShell script from any domain-joined workstation or server with the ActiveDirectory module:
# Script: Get-ExchangeSchemaVersion.ps1
# Description: Queries the 3 Active Directory naming contexts and outputs Exchange schema readiness
Import-Module ActiveDirectory -ErrorAction Stop
# 1. Query RootDSE for Forest & Domain Naming Contexts
$RootDSE = Get-ADRootDSE
$SchemaNC = $RootDSE.schemaNamingContext
$ConfigNC = $RootDSE.configurationNamingContext
$DomainNC = $RootDSE.defaultNamingContext
Write-Host "`n=== ACTIVE DIRECTORY EXCHANGE SCHEMA AUDIT ===" -ForegroundColor Cyan
Write-Host "Domain Controller Contacted: $($RootDSE.dnsHostName)" -ForegroundColor Gray
# 2. Query Schema Container (rangeUpper)
$SchemaObj = Get-ADObject -Identity "CN=ms-Exch-Schema-Version-Pt,$SchemaNC" -Properties rangeUpper
$RangeUpper = $SchemaObj.rangeUpper
# 3. Query Exchange Organization Container in Configuration NC
$OrgContainer = Get-ADObject -Filter 'objectClass -eq "msExchOrganizationContainer"' -SearchBase "CN=Microsoft Exchange,CN=Services,$ConfigNC" -Properties objectVersion
$ForestObjectVersion = $OrgContainer.objectVersion
$OrgName = $OrgContainer.Name
# 4. Query Microsoft Exchange System Objects (MESO) Container in Domain NC
$MesoObj = Get-ADObject -Identity "CN=Microsoft Exchange System Objects,$DomainNC" -Properties objectVersion
$DomainObjectVersion = $MesoObj.objectVersion
# Output Formatted Report
$Report = [PSCustomObject]@{
"Exchange Organization" = $OrgName
"Schema (rangeUpper)" = $RangeUpper
"Forest (objectVersion)" = $ForestObjectVersion
"Domain (objectVersion)" = $DomainObjectVersion
}
$Report | Format-List
# Interpret the results
$Status = switch ($RangeUpper) {
{$_ -ge 17000} { "Exchange Server Subscription Edition (SE) Ready" }
{$_ -ge 15337} { "Exchange Server 2019 / 2016 Latest CU Ready (CU12-CU14 / CU23)" }
{$_ -ge 15332} { "Exchange Server 2019 / 2016 Early CU (RTM-CU2)" }
{$_ -ge 15312} { "Exchange Server 2013 CU23" }
{$_ -ge 14734} { "Exchange Server 2010 SP3" }
Default { "Legacy or Incomplete Schema Preparation" }
}
Write-Host "Detected Level: $Status" -ForegroundColor Green
Verifying Replication Across All Domain Controllers
After running /PrepareSchema, ensure that the new rangeUpper value has fully replicated to all domain controllers in all Active Directory sites before proceeding with /PrepareAD or installing Exchange servers:
# Script: Check-SchemaReplicationAllDCs.ps1
# Description: Verifies rangeUpper consistency across all DCs in the forest
$DCs = Get-ADDomainController -Filter *
$ReplicationAudit = foreach ($dc in $DCs) {
try {
$val = (Get-ADObject -Server $dc.HostName -Identity "CN=ms-Exch-Schema-Version-Pt,$SchemaNC" -Properties rangeUpper).rangeUpper
[PSCustomObject]@{
DomainController = $dc.HostName
Site = $dc.Site
RangeUpper = $val
ReplicationState = ($val -ge 15337 ? "Synchronized" : "Pending Replication")
}
} catch {
[PSCustomObject]@{
DomainController = $dc.HostName
Site = $dc.Site
RangeUpper = "Unreachable"
ReplicationState = "Failed"
}
}
}
$ReplicationAudit | Format-Table -AutoSize
Summary Checklist for Exchange Administrators
- Schema Master Placement: Always execute
Setup.exe /PrepareSchemaon a member server in the same Active Directory site as the Schema Master FSMO role holder. - Replication Convergence: Verify that
rangeUppermatches across all domain controllers before proceeding to/PrepareAD. - Domain Preparation: Confirm that the
Microsoft Exchange System Objectscontainer (MESO) exists in all domains hosting Exchange recipients, not just the root domain. - Stale Objects: If preparing for an in-place upgrade to Exchange Server SE, audit and clean up stale legacy Exchange objects using our Exchange SE Active Directory Pre-Upgrade Runbook.