Every time I do an Exchange 2000/2003 to Exchange 2007 transition I have to run the same shell commands at the end to upgrade the default Email Address Policy, Address Lists, and Global Address List.
So I wrote this script to do it automatically. To use the script copy this code into Notepad and save it as “upgradeobjects.ps1” somewhere on the Exchange server.
Set-EmailAddressPolicy "Default Policy" -IncludedRecipients AllRecipients -ForceUpgrade Set-AddressList "All Users" -IncludedRecipients MailboxUsers -ForceUpgrade Set-AddressList "All Groups" -IncludedRecipients MailGroups -ForceUpgrade Set-AddressList "All Contacts" -IncludedRecipients MailContacts -ForceUpgrade Set-AddressList "Public Folders" -RecipientFilter { RecipientType -eq 'PublicFolder' } -ForceUpgrade Set-GlobalAddressList "Default Global Address List" -RecipientFilter {( Alias -ne $null -and (ObjectClass -eq 'user' -or ObjectClass -eq 'contact' -or ObjectClass -eq 'msExchSystemMailbox' -or ObjectClass -eq 'msExchDynamicDistributionList' -or ObjectClass -eq 'group' -or ObjectClass -eq 'publicFolder' ))} -ForceUpgrade
Then open the Exchange Management Shell, and execute the script.
Example:
C:tempupgradeobjects.ps1
There is nothing fancy in it like progress indicators or error handling, it just does what it needs to do and exits.
Pingback: How to Upgrade Address Lists During Exchange 2007 Migration | Exchange Server Pro
Pingback: Upgrade Email Address Policies During Exchange 2007 Migration | Exchange Server Pro