Skip to main content
Exchange Online restore fails due to restore API limitation
Updated over 2 weeks ago

❗ Important

This article applies toProduct edition: inSync Cloud


Problem description

Edit section

Exchange online restore fails with an internal error:

The primary SMTP address must be specified when referencing a mailbox.

Cause

Edit section

Due to the Exchange restore API limitation, the primary SMTP address of the user must match with the email address registered in inSync.

Traceback

Edit section

For procedure to download logs, see inSync user log files


📝 Note
++snip++[2018-12-22 1755:46,035] [ERROR] WRKID-22466 cloudapp-6091/799812/1003142/Exchange Online: Error creating mail folders. User: xyz@xyz.com. Error: Internal error. Response Code: 500 Text:<?xml version="1.0" encoding="utf-8"?><s:Envelope xmlns:s=" http://schemas.xmlsoap.org/soap/envelope/ "><s:Body><s:Fault><faultcode xmlns:a=" http://schemas.microsoft.com/exchang...ces/2006/types ">a:ErrorNonPrimarySmtpAddress</faultcode><faultstring xml:lang="en-US">The primary SMTP address must be specified when referencing a mailbox.</faultstring><detail><e:ResponseCode xmlns:e=" http://schemas.microsoft.com/exchang...es/2006/errors ">ErrorNonPrimarySmtpAddress</e:ResponseCode><e:Message xmlns:e=" http://schemas.microsoft.com/exchang...es/2006/errors ">The primary SMTP address must be specified when referencing a mailbox.</e:Message><t:MessageXml xmlns:t=" http://schemas.microsoft.com/exchang...ces/2006/types "><t:Value Name="Primary"> xyz@abc.com </t:Value></t:MessageXml></detail></s:Fault></s:Body></s:Envelope> (#100000001)++snip++



Note:
Exchange Online Backup Workflow:

  • For Exchange Online Mailbox backup inSync use Graph API which is a REST-based API where the user UPN or SMTP address is provided in the request URL itself and even if the UPN and Primary SMTP address are different this API will return success.

  • However, for Archive Mailbox backup and Restore inSync use EWS API which is a SOAP-based API where we need to explicitly send only the Primary SMTP address in the XML request.

  • So, to back up/restore Archive Mailbox, the inSync Admin needs to make sure that the inSync email id = Primary SMTP address of the user.

  • In case the user does not have Archive Mailbox then, in the backup flow only Graph API requests were made and the backup will be finished successfully.

Exchange Online Restore Workflow:

  • In the restore flow, we use EWS API and pass PrimarySmtpAddress in the request XML.

  • So the inSync Admin needs to ensure the user’s primary SMTP address and the email address registered with inSync are the same.

  • In case the PrimarySmtpAddress and inSync email address are different for any user the restore will fail.

Resolution

Edit section

Ensure the user's primary SMTP address and the email address registered with inSync are same. You can either change the email address registered in inSync or in Microsoft 365 admin center. The procedures for both are provided below:

To change the email address registered in inSync:

  1. Login to the inSync Management Console and click Users.

  2. Click the user name. This opens the user details page.

  3. On the Summary tab, click Edit.

  4. Replace the email address with the primary SMTP address and click Save.

To change the primary SMTP address in Microsoft 365 admin center:

  1. Login to the Microsoft 365 admin center.

  2. Click Users.

  3. From the drop-down list, select Active users.

  4. Select the user name and click Edit next to the username.

  5. From the already populated aliases, set the email address registered in inSync as primary.

  6. Click Save.

Verification

Restores should succeed without errors.

See also

Did this answer your question?