Where did my Remote Routing Address go?

Enable-RemoteMailbox is a powerful and useful command, sparing Exchange Hybrid admins the pain of creating and moving a local mailbox to Exchange Online. It does, however, have some issues occasionally – specifically when creating the required RemoteRoutingAddress.

From the official documentation, you get the provided example:

Enable-RemoteMailbox “Kim Akers” -RemoteRoutingAddress “kima@contoso.mail.onmicrosoft.com”

This usually works, however, from what I have seen, Exchange sometimes doesn’t treat the initial remote routing address as a distinct email address and it essentially disappears. It’s a bit quirky as Enable-RemoteMailbox doesn’t consume the EmailAddresses switch.

This is made more obvious in EAC, as the gui forces you to create the email address before it can be set as the Remote Routing Address.

If you have already created the remote mailbox, then you can run the command below to fix it up:

Set-RemoteMailbox -EmailAddresses @{add=”user@contoso.mail.onmicrosoft.com”} -RemoteRoutingAddress user@contoso.mail.onmicrosoft.com -identity <alias> -DomainController <FQDN of DC>

Another option is to run two separate Powershell commands when creating a remote mailbox. Note that the second one may fail if the DC you are connecting to isn’t aware of the remote mailbox object yet. You can get around this by using the same DC with the -DomainController switch or just waiting a bit and trying the second command again.

Enable-RemoteMailbox -identity <alias> -PrimarySmtpAddress user@contoso.com -RemoteRoutingAddress user@contoso.com  -Alias alias -shared -DomainController <FQDN of DC>

You will notice I am setting the RemoteRoutingAddress to the primary SMTP address in the first command. I do that because you have to set it to something. I plan on setting that in the next step to the actual remote routing address.

I also like update the alias here as well to ensure it matches to the existing SamAccountName in Active Directory, otherwise you may find it set to the “User Logon Name”. Of course, you can set this to anything you want.

Both the -shared and -DomainController switches are optional and available in the latest supported Cumulative Updates for Exchange 2013 and above.

Once enabled, add the additional email address with the correct RemoteRoutingAddress.

Set-RemoteMailbox -EmailAddresses @{add=”user@contoso.mail.onmicrosoft.com”} -RemoteRoutingAddress user@contoso.mail.onmicrosoft.com -identity <alias> -DomainController <FQDN of DC>

The RemoteRoutingAddress can be anything unique. It’s typically “user@<tenant>.mail.onmicrosoft.com” and you should already have an existing On-Premises send connector to ensure messages are routed to the Exchange Online mailbox.

The remote mailbox now has the correct email and remote routing address set and, more importantly, they should stick! I have not tested this against Exchange 2019, but I would assume the issue is still there.

Happy Hybriding.

Published by adavid6

Grumpy Old Exchange MVP. My old site was lost: https://web.archive.org/web/20180307110652/http://no-one-uses-email-anymore.com/ I have been an Exchange MVP since 2002. I also had the honor of naming “You had me at EHLO” for the Exchange Product Group Blog way back in the early 2000s. I attempt to answer forum questions on TechNet: https://social.technet.microsoft.com/profile/andy%20david/ and can be found on Twitter: https://twitter.com/adavid6 Reddit: https://www.reddit.com/user/adavid1608 Microsoft Tech Community: https://techcommunity.microsoft.com/t5/user/viewprofilepage/user-id/86

One thought on “Where did my Remote Routing Address go?

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: