In a previous blog I mentioned the tribulations in getting Exchange 2007 Sp2 management tools on to a Windows 7 workstation. This need was generated by some issue between Backup Exec 12.5 and Exchange 2007 failing to backup up LCR protected stores. As an interim I was looking to get an extract of the mailbox data to confirm that all was well in the database store. This is where the command line powershell interface to Exchange 2007 comes into its own.
By identifying the store database using Get-MailboxDatabase and then checking the permissions that the user I had decided to use for the extract I was able to give that users permissions to the mailboxes with
Get-MailboxDatabase ‘servernamename of the mailbox database’ | get-adpermission -user administrator
to see the current rights and then give full access to the mailboxes.
Get-MailboxDatabase ‘servernamename of the mailbox database’ | get-adpermission -user administrator -accessRights GenericAll
The mailboxes were then exported using
get-mailbox -Database ‘servername of database’ | export-mailbox -PSTFolderPath z:psts
A slower but effective way of getting the exchange 2007 mailboxes into pst files