IMCEAEX NDRs and how to fix them…

Matt Ellis
Oct 19, 2018 · 3 min read

If you’ve ever migrated email, restored email or aimlessly messed around with mailboxes and email address attributes, chances are that you’ve encountered non-delivery reports (NDR) with an IMCEAEX error similar to this:

The reason this happens is that in Exchange Server, internal emails are addressed and routed using X.500 addresses, rather than with SMTP addresses. This X.500 address is found within Active Directory as the legacyExchangeDN attribute. When that legacyExchangeDN/X.500 address can no longer be resolved to a recipient, a 5.1.1 NDR occurs.

In my experience this happens most frequently when migrating email from one Exchange org to another. Post-migration people go to reply to one of their old/migrated emails and they end up with this NDR in their mailbox.

So, how do you fix this? Well, you have one of two methods available to you:

Get the legacyExchangeDNs from the source domain

If your issue is caused by migrating email and you still have access to the source environment you can export a list of the legacyExchangeDN attributes and apply them as X.500 addresses to the destination mailboxes.

To do this you can use a command similar to the following:

Set-Mailbox -Identity "" -EmailAddresses @{add="X500:/O=ORGNAME/OU=EXCHANGE ADMINISTRATIVE GROUP (FYDIBOHF23SPDLT)/CN=RECIPIENTS/CN=fcbdf1571cd0480839997fe4f620b70"}

Use the NDR to create an X.500 address

This could be a painful exercise if you have migrated lots of mailboxes but it is possible to use the IMCEAEX message in the NDR to generate your X.500 address. To do this take the string in the NDR and perform the following (taken from here):

  • Replace any underscore character (_) with a forward slash character (/)
  • Replace “+20” with a space
  • Replace “+2E” with a full stop (period, for you yanks)
  • Replace “+28” with an opening bracket character (
  • Replace “+29” with a closing bracket character )
  • Delete the “IMCEAEX-” string from the beginning
  • Delete the “” string at the end
  • Add “X500:” to the beginning


Will become:


Now you can use the string to add your X.500 address using the following PowerShell command:

Set-Mailbox -Identity "" -EmailAddresses @{add="X500:/O=ORGNAME/OU=EXCHANGE ADMINISTRATIVE GROUP (FYDIBOHF23SPDLT)/CN=RECIPIENTS/CN=fcbdf1571cd0480839997fe4f620b70"}

Convert IMCEAEX to X.500 Script

If you want a bit of help to convert the IMCEAEX string to an X500 you can use the following script to do it for you:

You can run the script with or without the IMCEAEX string as a parameter. If you don’t supply it, you will be asked to paste it in.

ConvertIMCEAEXToX500.ps1 [-IMCEAEX]

365 UC

Stories from the world of UC by a bunch of UC…

Medium is an open platform where 170 million readers come to find insightful and dynamic thinking. Here, expert and undiscovered voices alike dive into the heart of any topic and bring new ideas to the surface. Learn more

Follow the writers, publications, and topics that matter to you, and you’ll see them on your homepage and in your inbox. Explore

If you have a story to tell, knowledge to share, or a perspective to offer — welcome home. It’s easy and free to post your thinking on any topic. Write on Medium

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store