November 21, 2014

Moving mass Mailboxes from Exchange 2003 to Exchange 2010

Assuming you already have Exchange 2003 and Exchange 2010 working in co-existence in your large single forest environment. These are the following steps you need to take when moving mailboxes in bulk from exchange 2003 to exchange 2010.

1) You need to take a look at your .config file on your target Exchange 2010 CAS server. By default the maximum number of mailboxes you can move at a given time is 2. If you are moving mailboxes in bulk you will need to increase it to your desired number of mailbox moves, in this example, we'll make it 50.

In a normal installation of exchange, you will find the .config file located here to edit in notepad:

C:\Program Files\Microsoft\ExchangeServer\V14\Bin\MSExchangeMailboxReplication.exe.config

MaxActiveMovesPerSourceMDB = "50"
MaxActiveMovesPerTargetMDB = "50"
MaxActiveMovesPerSourceServer = "50"
MaxActiveMovesPerTargetServer = "50"

After making the above changes, you will need to restart Microsoft Exchange Mailbox Replication service. 

Note: I recommend making these changes afterhours in any environment. Restarting this service will not disrupt mailflow during the business day but it is ideal practise to make these changes after hours in your environment.

2) Create a .csv file having the Alias or Displayname in the format below and save it as batchusers.csv


Then you need to run the command from the Exchange Management Shell on your Exchange 2010 server.

Import-CSV "C:\Batchusers.csv" | foreach {New-MoveRequest -Identity $_.alias -TargetDatabase $_.TargetDatabase}

With a baditemlimit parameter in there as well:

Import-CSV "C:\Batchusers.csv" | foreach {New-MoveRequest -Identity $_.alias -TargetDatabase $_.TargetDatabase -BadItemLimit 100}

You can also use the Get-Content switch to move mailboxes in bulk. Some may say this is easier. Using the Display Name or alias of Users and in notepad, save the notepad file as a .txt file like batchusers.txt
In Exchange Management Shell type this command:

Get-Content -Path C:\MoveMailbox\batchusers.txt | New-MoveRequest -TargetDatabase "NameOfMailboxDatabase" 

No comments:

Post a Comment