Forum Discussion
tkerby
Jan 17, 2022Copper Contributor
Duplicate emails on two domains (.com and .co.uk)
Hi I'm in the process of migrating email from another service and I have three domains including a .com and a .co.uk. I'd like all emails to mailto:Email address removed to go to mailto:Email add...
surajbudhani
Microsoft
Jan 17, 2022You can either use email address policy to add secondary email address to all the users.
Or you can just run one PowerShell command to update the secondary email address.
$AllMailbox = Get-Mailbox -ResultSize Unlimited
Foreach($A in $AllMailbox){
$NewEmail = $A.Alias + "@domain.co.uk"
Set-Mailbox $A.Alias -EmailAddresses @{Add=$NewEmail}}
If the alias is john and email address is "john @ domain.com". This will add an additional SMTP as "john @ domain2.co.uk"
Or you can just run one PowerShell command to update the secondary email address.
$AllMailbox = Get-Mailbox -ResultSize Unlimited
Foreach($A in $AllMailbox){
$NewEmail = $A.Alias + "@domain.co.uk"
Set-Mailbox $A.Alias -EmailAddresses @{Add=$NewEmail}}
If the alias is john and email address is "john @ domain.com". This will add an additional SMTP as "john @ domain2.co.uk"