Thought it would be worth sharing the information and testing I have gathered to manual change the user principle name, where directory sync is unable to when using O365 Exchange Online. We have only seen this dirsync issue with betaearly trail tenant accounts.
Please note that this change will stop directory synchronisation for up to 24hrs (some cases 72hr), no mailbox migrations or user creations should occur until dir sync is re-enabled. Federated Users will still continue to work (login) and users and still fully use the service
Launch Microsoft Online Modules for Powershell and login
Connect-msolservice
Disable Dir Sync
Set-MsolDirSyncEnabled -EnableDirSync $false
Change user accounts
Set-MsolUserPrincipalName -UserPrincipalName user@olddomain.co.uk NewUserPrincipalName user@newdomain.co.uk
Once user UPN is updated online Update users AD UPN
Launch ADUC
Once all UPNs have been update (on-prem and cloud) enable DirSync (in testing this took 4hrs however MS state it can take upto 72hrs)
Set-MsolDirSyncEnabled -EnableDirSync $true
For more information please see: http://www.ultimate-communications.com/2012/02/troubleshooting-dirsync-and-upn-office-365/
Hi, im about to update the original article with some new info regarding this to look at the original article for more info and how to really solve this.