How to Convert a mail enabled user to a mailbox enabled user in Exchange 2010 using PowerShell

Hi All,

There may be times when you have users in your environment that have Active Directory accounts to log on to the domain but their email accounts are hosted outside your Exchange environment. In order to have these people visible in the Global Address book they are configured as a Mail-Enabled users. What this means is they do not have a mailbox in your Exchange org but their Active Directory account is configured with an external email address and users in your org can use the Global Address list to send them emails. For example Joe Testuser is a consultant for Pipe2Text.com and is not an actually employee of the company. He has a gmail account he likes to use for his email. He does not have a mailbox in the Pipe2Text Exchange Org but users internal can find him in the Global Address list and use this to email his gmail account. Now lets say the people at PipeText.com come to really like Joe TestUser and they decide to hire him as an actual employee which means he will receive an internally hosted mailbox in the Pipe2Text Exchange Org. He already has an Active Directory which has certain permissions to resources in the Domain that will be gone if you delete his account and start over by creating a new AD account with a mailbox. What you need to do is convert his Mail-Enabled user account into a Mailbox-Enabled account. This can be done easily from the Exchange Management Shell.

First you will want to get the name property for Joe Testuser’s Mail-Enabled account. If you simply type the following command you will receive a list of all Mail-Enabled users:

Get-MailUser

Depending on your environment, this may yield a large list of users. If you were looking for Joe Testuser specifically and weren’t exactly sure how his name property was presented, you could type the command below to bring up all Mail-Enabled users containing the word Joe:

Get-Mailuser *Joe*

The output will look as follows:

Name                                     RecipientType
  —-                                        ————-
Joe TestUser                           MailUser

Now that you have the name (in our case Joe Testuser) you can use it to type the following command to convert the Mail-Enabled user to a Mailbox-Enabled user and creating the mailbox for them in an Exchange database named “EXCHDB01”:

Get-Mailuser “Joe TestUser” | Enable-Mailbox -Database EXCHDB01

The output should look similar to the following:

Name                      Alias                ServerName       ProhibitSendQuota
  —-                         —–                   ———–            ——————
Joe TestUser           Jtestuser           mailserv01          unlimited

Now that the mailbox has been created you can go into the Exchange Management console or Type “Get-Mailbox Jtestuser | FL” to review the properties of the user.  After reviewing the new mailbox you can do any cleanup as necessary such as removing the external email address that is leftover or possibly changing some other property to comply with your environments standards before you the user begins using the mailbox. If you would like to find out what else can be achieved using the Enable-Mailbox cmdlet you can check help by typing “Get-Help Enable-Mailbox”. As always, using a lab environment is the safest way to test and learn these commands before using them in a production environment. Hope this helps. If you have any questions or feedback please leave a comment.

 

 

Share Button
Author: BC

BC is a Pipe2text.com contributor and has been an IT Professional for 15 years. He currently works as a Sr. Systems Engineer at a private firm. He enjoys working with Active Directory, Exchange and VMware among other technologies.


Leave a Reply

Your email address will not be published. Required fields are marked *