Migrate LegacyExchangeDN
Preserve reply functionality by migrating legacyExchangeDN to X500 addresses.
LegacyExchangeDN Migration Flow
Overview
Why LegacyExchangeDN Matters
When users reply to older emails after migration, Outlook uses the original
legacyExchangeDN stored in
cached recipient addresses. Without migrating this value to the target system,
replies will bounce with "recipient not found" errors.
The Problem
Old emails contain the source system's legacyExchangeDN. The target system doesn't recognize these addresses by default, causing delivery failures when users reply to pre-migration messages.
Primary Method: Transfer X500 Task
Using Cloudiway's Built-in Feature
Cloudiway offers a global task that automatically migrates legacyExchangeDN values to X500 proxy addresses in Office 365.
Navigate to Mail Migration in your project
Ensure the mapping table is properly populated
Select Transfer X500 from the global tasks menu
The task reads source legacyExchangeDN and adds it to target proxyAddresses
Requirement
Azure AD Connect Environments
Critical Limitation
When your on-premises Active Directory synchronizes with Office 365 through Azure AD Connect, the Office 365 tenant becomes read-only for synchronized attributes. Cloudiway cannot directly modify user proxy addresses in this scenario.
Why This Happens
Azure AD Connect establishes the on-premises Active Directory as the authoritative source. Any changes to synced attributes must be made in on-premises AD, then replicated to Office 365.
Manual Migration Steps
For Azure AD Connect environments, follow this manual process to migrate legacyExchangeDN values:
Export LegacyExchangeDN
Export the legacyExchangeDN values from your source system.
# On-premises using CSVDE:
csvde -f export.csv -r "(objectClass=user)" -l "mail,legacyExchangeDN" # Office 365 using PowerShell:
Get-Mailbox | Select PrimarySmtpAddress,LegacyExchangeDN | Export-Csv export.csv Import to Active Directory
Use PowerShell to add X500 addresses to the proxyAddresses attribute in your on-premises Active Directory.
# PowerShell script to add X500:
Import-Csv export.csv | ForEach-Object {
$user = Get-ADUser -Filter "mail -eq '$($_.mail)'"
$x500 = "X500:" + $_.legacyExchangeDN
Set-ADUser $user -Add @{proxyAddresses=$x500}
} Wait for Azure AD Connect Sync
Allow Azure AD Connect to replicate the changes to Office 365. This typically occurs within 30 minutes but may vary based on your sync schedule.
Tip: Force a sync with Start-ADSyncSyncCycle -PolicyType Delta
Important Disclaimer
Cloudiway does not provide support for Active Directory or Azure AD Connect configurations. The steps above are provided as general guidance only. Consult your IT team or Microsoft documentation for specific implementation details.