Five checks before you install anything. Each one avoids a problem that is harder to fix once accounts are in the cloud.
The domain is verified
contoso.com shows as Verified in admin.microsoft.com › Settings › Domains.
Every account has the right sign-in name
Each user's UPN in AD must end in the verified domain. An account ending @ad.contoso.com arrives in Microsoft 365 as @contoso.onmicrosoft.com instead.
$base = "OU=CON-Users,OU=Contoso School,DC=ad,DC=contoso,DC=com" Get-ADUser -SearchBase $base -Filter * -Properties mail, proxyAddresses | Select-Object SamAccountName, UserPrincipalName, mail | Format-Table -AutoSize (Get-ADUser -SearchBase $base -Filter "UserPrincipalName -notlike '*@contoso.com'").Count # must be 0
Admin accounts are outside the sync scope
You will sync CON-Users only. Make sure CON-Admins sits beside it, not inside it. The Active Directory OU guide shows how to move it.
The sync server can reach Microsoft
| Needs | Detail |
|---|---|
| Operating system | Windows Server 2016 or later, joined to the domain |
| Memory | 4 GB |
| .NET Framework | 4.7.1 or later |
| Outbound | TCP 443 and 80 to the internet. 80 is for certificate checks |
| To the DCs | The normal AD ports |
Pick where it runs
Use a member server in CON-Infrastructure, such as CON-SYNC-01. A domain controller works too, but keeping the agent off the DCs keeps their job simple.
Done when
The domain is verified, the UPN count is 0, CON-Admins is outside CON-Users, and the server can open https://login.microsoftonline.com.


