Secondary smtp address is not syncing.

Amit Rawat 26 Reputation points
2020-10-10T11:43:59.397+00:00

hello,
We have Exchange online and exchange 2010 in hybrid mode as migration is on. We have few non mailbox users in Active Directory those login id is different (let say 456@keyman .com) whereas their email id would be like "username@keyman .com" and "username@keyman .onmicrosoft.com". I need both for business reason. Now what is happening , when AD connect sync ( on prem to O365, we have one way sync setup), "username@keyman .com" is syncing but not the other one, instead it is making smtp address in user email address like "456@keyman .onmicrosoft.com". Now this is happening when i didnt add anything in proxy address of user in Active Directory except SMTP:username@keyman .com . I tried to add smtp:username@keyman .onmicrosoft.com but NADA.. nothing is happening. I tried to add smtp:test@keyman .com and it is syncing to O365. Can ayone let me know how to get thsi smtp:username@keyman .onmicrosoft.com in mailbox email adddress.

Regards
Amit Rawat

Microsoft Office Online Server
Microsoft Office Online Server
Microsoft on-premises server product that runs Office Online. Previously known as Office Web Apps Server.
639 questions
{count} votes

Accepted answer
  1. Andy David - MVP 147.9K Reputation points MVP
    2020-10-11T16:47:37.363+00:00

    So thats the question.
    If they need that mailbox, then you can't remove the license and purge the user unless you move the mailbox back on-prem, then remove all the licenses and purge from Azure and resync.

    I tested this and this works every time using msolservice module:
    Change the values on-prem. Make the primary SMTP address and UPN match. Set the alias/mailnickname as required so it will be
    mailnick@keyman .onmicrosoft.com

    Then:

     connect-msolervice  
     remove-MsolUser -UserPrincipalName  SAM@domain.com  
    
     remove-MsolUser -UserPrincipalName  SAM@domain.com -RemoveFromRecycleBin  
    

    Resync and it should be as you want it.

    However -as I said, ONLY do this if you do not need the mailbox or any existing data in the current Azure account since you wont be able to recover it from Azure once you remove it from the Recycle Bin

    2 people found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. Andy David - MVP 147.9K Reputation points MVP
    2020-10-10T15:35:11.303+00:00

    Ok I think I understand.
    You should make the UPN/User Logon match the Primary SMTP Address. Not only is that a best practice and recommended.

    If you want sam.jason@keyman .onmicrosoft.com, then make the following changes:

    UPN: sam.jason@keyman .com
    PrimarySMTPAddress: sam.jason@keyman .com
    Alias/MailNickName: sam.jason

    If you do not want to change the UPN to match the Primary, then at minimum set the following:
    PrimarySMTPAddress: sam.jason@keyman .com
    Alias/MailNickName: sam.jason

    After it syncs, then you should see a proxy address of

    sam.jason@keyman .onmicrosoft.com in Azure/365.

    1 person found this answer helpful.

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.