Forum Discussion

Jonathan Klein-Wiele's avatar
Jonathan Klein-Wiele
Copper Contributor
Feb 27, 2018
Solved

SMTP-addresses not in sync with AD

We have an AADSync enabled tenant syncing the users to Office 365 and have ADFS running. We have NO Exchange hybrid setup. Mailboxes are on-premises Exchange.

I accidently created for some users a Mailbox and deleted it again. With this, the primary SMTP-address changed from the right mailadress, which was synced from AD, to the tenants xxx.onmicrosoft.com

 

I just want to change it back to the primary SMTP-address of the on-premises Mailbox which worked well until i created the mailboxes.

I tried to temporary change the primary SMTP on-premises and change it back. But the first change worked, the change back not. Some ideas? Is it possible to change the SMTP-addresses in O365 or is it possible to "force" a sync from AD?

 

Thanks!

9 Replies

    • Jonathan Klein-Wiele's avatar
      Jonathan Klein-Wiele
      Copper Contributor

      Thanks for your feedback, I tried all your hints but none worked... But we will move in the next weeks to hybrid and I hope problems are gone then.

      • Pablo R. Ortiz's avatar
        Pablo R. Ortiz
        Steel Contributor

        if you don't comnpletely remove the EXO created mailboxes, Hybrid/Migration won't work for those

  • set-mailuser -Identity abc -EmailAddresses @{Add="abc@abc.de"} did not work: The operation on mailbox "abc" failed because it's out of the current user's write scope. The action 'Set-MailUser', 'EmailAddresses', can't be performed on the object
    abc' because the object is being synchronized from your on-premises organization. This action should be performed on the object in your on-premises organization. But if I Change on-premises it doesn't work
    • VasilMichev's avatar
      VasilMichev
      MVP

      You should be able to use the -WindowsEmailAddress parameter for this. The new address you specify should be set as the Primary SMTP, while the old primary one will be kept as secondary. The cmdlet will also work against synced users.

       

      If that's not a viable solution for your scenario, you can force-delete the mailbox in O365 and provision the object anew. Use the method outlined here for fastest resolution: https://blogs.technet.microsoft.com/exchange/2018/01/17/permanently-clear-previous-mailbox-info/

      • Jonathan Klein-Wiele's avatar
        Jonathan Klein-Wiele
        Copper Contributor

        Ok, thanks guys, seems that the reply from Vasil worked. It needed some time but now I got the mails and could fix the issue!

         

        Thanks also for all the other hints!