Home > Exchange 2007, Exchange 2010 > Upgrading Exchange EAP and Address Lists (Opath Format) for Exchange 2007\2010

Upgrading Exchange EAP and Address Lists (Opath Format) for Exchange 2007\2010

For administrators that have supported Exchange since Exchange 5.5 or 2003 days, you know that if you have a large organization with multiple domains, you likely have several Address Lists and Email Address Policies that need to be upgraded to Exchange 2007\2010 format.  The problem is when you migrate to Exchange 2007 or 2010, the syntax or Opath format is no longer supported in the old version.   Essentially the Opath format is a LDAP filter, where the syntax between the different types of Exchange versions is drastically different.   This causes old address list queries to not produce any user while searching.  (Typically from the Outlook address book or GAL)

This TechNet Article goes into more detail on the subject.

“After installing Exchange 2007 into your existing Exchange organization, the address lists and recipient policies must have OPATH filters specified in order to administer them from the Exchange 2007 tools. OPATH is the basis for the filtering syntax used by PowerShell, and is therefore the filtering syntax used by Exchange Server 2007.”

The script in the article does not change invalid or poorly written syntax that is already in place; it merely updates the syntax to Opath Format and gets them up to Exchange 2007\2010 standards.  If your LDAP filter is searching for mailboxes, DLs, and everyone named “BOB” in their Display Name at the global level, then you need to rethink what you want your filters to look for.  (We’ll get into that later)

Let’s Convert your EAP and Address Lists to Opath Format
To convert all legacy address lists, GALs, and email address policies, without prompting, run three commands:

Update any Address Lists in Legacy Format
Get-AddressList | WHERE { $_.RecipientFilterType -eq ‘Legacy’ } | foreach { Set-AddressList $_.Name -RecipientFilter (.\ConvertFrom-LdapFilter $_.LdapRecipientFilter) -ForceUpgrade }

Update any Global Address Lists in Legacy Format
Get-GlobalAddressList | WHERE { $_.RecipientFilterType -eq ‘Legacy’ } | foreach { Set-GlobalAddressList $_.Name -RecipientFilter (.\ConvertFrom-LdapFilter $_.LdapRecipientFilter) -ForceUpgrade }

Update any Email Address Policy in Legacy Format
Get-EmailAddressPolicy | WHERE { $_.RecipientFilterType -eq ‘Legacy’ } | foreach { Set-EmailAddressPolicy $_.Name -RecipientFilter (.\ConvertFrom-LdapFilter $_.LdapRecipientFilter) -ForceUpgrade }

Once these have been ran, we can now look at what a converted legacy address list versus a new 2007\2010 address list looks like.

From a 2007\2010 Exchange Management Console, the converted 2003 address list would look similar to this:

If you notice, you cannot edit the syntax, but you can old “Preview”.    In order to update this syntax, you must use Exchange PowerShell.

Conversely, an Exchange 2007\2010 Address List would look similar to:

image image
The one caveat is you lose the ability to edit any conditions like Display Name Filtering, which you previously could do in Exchange 2003 using the GUI.   This is quite the inconvenience and requires an additional step.

If you need to change the filtering rules or syntax, you can following this TechNet article: http://technet.microsoft.com/en-us/library/dd335105.aspx.

In my example from above, you could use:


Set-AddressList “Alaska” -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’))))) -and (ObjectCategory -like ‘user’))) -and (DisplayName -like ‘Alaska*’))}

The highlighted portion in Red is where you would change the syntax or search criteria for your filter.  Note that, depending on your filtering rules, you may get different results depending if the mailbox is on Exchange 2003, 2007\2010.   Without knowing your environment, you may have to perform a trial and error setup.

Worse case, if you want to simplify your filter by using a specific attribute such as the DisplayName use this:
Set-AddressList “Alaska” -RecipientFilter {Displayname –Like ‘*Alaska*’}

You can use just about any other type of attribute such as mail, X400 or userPrincipleName, depending on the complexity of your environment.

Best of Luck.

Ed McKinzie

  1. July 9, 2014 at 7:03 PM

    Very good article! We will be linking to this great article
    on our site. Keep up the great writing.

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: