What is the best way of fixing Office 365/AD accounts with no target address created

Copper Contributor

I have several Active Directory accounts, 50 plus, that were created using AD and not Exchange Admin Center, and as a result, these accounts are missing SMTP/smtp, Target Address and MSEXCHREMOTERECIPIENT attributes. I have tried manually entering them in the Attribute Editor, but then about a third of the time, since they have already synced to Office 365 it creates a duplicate account, username1234@domain.mail.onmicrosoft.com . My question is two fold, first what is the best way of fixing this to avoid making the duplicate account, and then the second question is, once the bad duplicate account is created, how do I fix it? I need the target address as both my scanner and Asset Management applications require the target address to send mail to the users. Any help is greatly appreciated.

5 Replies
In the Exchange Management Shell (on-premises to your Exchange Server) run Enable-RemoteMailbox <name> -RemoteRoutingAddress <name>@tenantname.mail.onmicrosoft.com and this will enable them for Exchange properly. You might need to set them as shared mailboxes or resources etc. as appropriate for the individual mailboxes.

The 1234 duplicate scenario will resolve itself once the duplicate is fixed. Using the DirSync errors view in the Office 365 Admin portal (under Reports) see who is the duplicate and resolve where the issue is. Note that email addresses on one object can duplicate with UPNs on other objects and that might be the source of the problem as well

Brian Reid
Office 365 MVP

Brian, thanks for the quick response, but would you be able to elaborate? I was working on one duplicate earlier and after moving the User Object into an unsynced OU, and then syncing, I then replaced him in the original OU and in Active Users/Mail Settings/ It said to migrate his account, but when I did the migration failed because no listening device was listening to our service on the end point. 

Some time ago i blogged about this. The scenario is slightly different but if i understand you correctly this is something you can try.

 

https://jerrymeyer.nl/2017/08/03/fix-duplicate-exchange-guid-errors/

 

This blogpost refers to duplicate exchange guids due to a misconfiguration of the user accounts in AD which are synced tru AADconnect

Jeff, thanks for the reply, I am trying this. Is this also the way to solve the issue when an account is username1234@tsus.mail.onmicrosoft.com?

 

Also, since we have recently changed our way of creating AD accounts from directly on the AD server, to using our Exchange on Prem via the Web and Choosing New User and Office 365, when it creates the new 365 account, it is preventing me from logging into the new users account, and I can not determine why this is occurring, their AD attributes appear to be correct, as do the Office 365 settings, yet if I try to log into the new users account, when I enter the credentials it doesn't accept is and it doesn't offer any error message either. Any thoughts?

In my opinion when you have a hybrid situation the way to create a new user is to create everything on-premise. Next up sync the user account and migrate the mailbox from on-premise to online.

 

Every duplicate issue you can solve due to stopping the sync first -> remove the msol user -> fix the user account onpremise - sync the user again and attach the mailbox.