Create bulk mailboxes in Exchange 2010 (or Exchange 2013/Exchange 2007)

by Bharat Suneja

I used to save code snippets as blog posts earlier. Resuming the practice, so don’t be alarmed by lack of text in this post. If you want to see detailed posts about creating bulk mailboxes, check out these previous posts:

Create 5 test mailboxes – username = “tester” + number.

$pw=(get-credential).password;for ($i=1; $i -le 5; $i++){$username=”tester”+$i;$upn=”[email protected]“;write-host “Username:”$Username “UPN:”$upn;new-mailbox -name $username -alias $username -password $pw -userprincipalname “$upn”}

Change the highlighted number in the condition statement to create as many mailboxes as you need. Change to a valid UPN suffix from your Active Directory forest.

As indicated in above posts, if you’re on Exchange 2007, you’ll need to specify the Database parameter. Exchange 2010 and later can select the mailbox database automatically (but still allow you to specify it if you want).

{ 0 comments… add one now }

Leave a Comment

Previous post:

Next post: