Tuesday 16 September 2014

Exchange PowerShell Cheat Sheet

 My plan it to add to this as I go, with any useful Exchange PowerShell commands.

This shows all of the Mailbox database copies for a database called “MBX Name”
Get-MailboxDatabase “MBX Name” | Format-List DatabaseCopies

This shows the dedicated DAG replication network.
Get-DatabaseAvailabilityGroupNetwork

This begins a mailbox move for “User” to a database called “MBX Name”
New-MoveRequest “User” –TargetDatabase “MBX Name”

This moves all of the users listed in C:\MyMigration to a database called “MBX Database”
Get-Content C:\MyMigration | New-MoveRequest –TargetDatabase “MBX Database”

This lists the progress of the mailbox migration for users listed in C:\MyMigration
Get-Content C:\MyMigration | Get-MailboxStatistics

I recently used this simple command to find where a generic e-mail account resided within Exchange.

Get-MailboxStatistics –Identity “Mailbox”