Bulk create mailboxes from existing users in Exchange 2013

I have 6 OU's containing about 1050 users total. I need to assign them mailboxes on our Exchange 2013 server. I would like all these mailboxes to go into a particular database. Any idea of the commands I need to run to make this happen since ECP doesn't let us select multiple accounts like we could in 2010?
LVL 8
Casey WeaverNetwork EngineerAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Michael ChisholmCommented:
****COMMANDLINE WAY****

do an export of the users in AD to create a csv file the use this power shell script to create the mailboxes

 Import-CSV adusers.csv | ForEach {New-Mailbox -Alias $_.alias -Name $_.name -userPrincipalName $_.UPN -Database “Mailbox Database” -OrganizationalUnit Users -Password $Password}


here is a site that explains in steps
http://www.codetwo.com/admins-blog/bulk-creation-of-mailboxes-on-microsoft-exchange-server-200720102013/

If the CSV is too complicated for you then this may help as well.

https://technet.microsoft.com/en-us/library/Aa998251(v=EXCHG.150).aspx


*********GUI Way***************

Navigate to you exchange management console
then go to recipient Configuration
then right click Mailbox and select new user
Choose the existing users you want to create (you can select in bulk from this screen)
on the next window you can  choose the database and other features
0
Amit KumarCommented:
Please try below one as you have users existing in OU just need to create mailboxes.

You can change searchbase OU according to your OU DN and if these are not nested OU then you will have to do it with one OU at once.

Import-module activedirectory

$users = Get-ADUser -LDAPfilter '(name=*)' -searchBase {OU=Employees,DC=contoso,DC=lab} 
foreach($user in $users)
{
   Enable-Mailbox -Identity $user.SamAccountName -Database <DBName>
}

Open in new window

1

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Casey WeaverNetwork EngineerAuthor Commented:
This solution was perfect, cut and paste and fill in the necessary info (like OU). Thanks alot!
1
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Exchange

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.