If you’re hosting your email with Microsoft’s Office 365 service, you may be using shared mailboxes. You should if you aren’t, they’re a great way to create email addresses that don’t consume a license. Shared mailboxes can also be shared.
I have a quite a few domains added to my Office 365 account and I wanted to create unique shared mailboxes for a couple of my domains. So I logged into Office365 and go to create the 2 shared mailboxes.
I wanted the following
I created the first shared mailbox without any issue, then when trying to create the second shared mailbox I came across this error.
You can’t do this through the admin center because it tries to enforce uniqueness of the alias but does not take into account the domain name. Which I think is kind of crazy, there has to be literally thousands of users that would need this functionality.
You have to use PowerShell to achieve this. First, you’ll need to connect your local session to your office365 account. You can do this following the steps outlined in the following Microsoft help document. I’ll outline the steps below incase the document moves or disappears.
$UserCredential = Get-Credential
Step Two – Connect to Office365
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
Step Three – Connect the session
Import-PSSession $Session -DisableNameChecking
If you don’t see any errors, you can move onto the next step. If you see the following error:
Import-PSSession :Files cannot be loaded because running scripts is disabled on this system.
You will need to change your PowerShell Execution Policy
Step Four – Create the shared mailboxes
New-Mailbox -Name "Social Mailbox" -Shared -PrimarySmtpAddress [email protected]
Step Five – Remove the session
PowerShell Execution Policy
I found this information over on Tachytelic.net thanks Paulie!
Open PowerShell as the administrator
Select ‘Y’ when prompted and you’ll be able to connect.