Roll back error during SfB user migration to Teams

In my latest project, I had the challenge to migrate an entire organization with 4.000 users from Skype for Business OnPrem to Micrsoft Teams in just two weeks. The customer planned to replace their current GoTo Meeting solution with Microsoft Teams. Of course, challenge accepted. During the migration I had to move the users from OnPrem to Skype for Business Online aka Teams. The migration to the cloud failed for some users with the message “An unknown error occurred while trying to roll back the user.” It took some time to resolve this error and this blog post is about it.

Current infrastructure – Skype for Business OnPrem

In this scenario the customer has implemented a Skype for Business Server 2019 OnPrem. Of course, it exists an Exchange Server 2016 for messaging and unified messaging services. For Azure AD synchronization the customer uses Azure AD sync with password hash sync. In process to implement Enterprise Voice as a PBX replacement, the management decided to freeze the current status and to move forward to Microsoft Teams. The current meeting solution, based on GoTo Meeting, should be replaced by Microsoft Teams worldwide. Some users are already using Enterprise Voice and we couldn’t switch to Teams Direct Routing in this short period of time.

Therefor we decided to use the given Skype for Business Hybrid setup to migrate all users without Enterprise Voice feature into the cloud and to assign the Teams Only upgrade policy to them.

During the migration of the first users, I had some problems with some of them. The Powershell reported an unknown error while trying to roll back the user.

Error message while SfB user migration to Teams
Error message during SfB user migration to Teams

What da hack? Roll back the user? What happens here?

Unknow error to roll back the user – try to find a root cause

Microsoft implemented with Lync 2013 and Exchange Server 2013 a new feature called Unified Contact store (UCS). With UCS Lync uses the Exchange user mailbox as contact store. Once enabled, all Lync based contact lists migrates to UCS. Of course you can disable this feature and new users will use the Lync database as contact store again. But users enabled for UCS in the past won’t revert automatically. You have to migrate the contact store to the Lync database by PowerShell.

The migration process checks the current contact store configuration. If UCS is active, it will roll back the contacts to Lync and continue the migration to SfB Online aka Teams afterwards.

So, it looks like some users in this environment were enabled for Unified Contact store even the feature itself is currently disabled. During the migration process to Teams the system tried to roll back the contact store and this process failed. But why did it fail?

Further analysis showed that the partner application in Exchange for Skype for Business exists and is valid.

Verify SfB partner application in Exchange OnPrem
Verify SfB partner application in Exchange OnPrem

How does the roll back process works?

The Exchange Web service triggers the UCS rollback. It is mandatory that the computer must connect to the Exchange Web Service from where you start the migration. To test the connectivity, you can use the Test-CsExStorageConnectivity command let. In this scenario the test failed. If you take a closer look at the error message, you can see that a web proxy is used for the connection:

Error in testing Exchange connectivity from Skype for Business server
Error in testing Exchange connectivity from Skype for Business server

And for some reason it let the connection fail.

As always in such a scenario, it is best practise to use a direct connection without a proxy. To solve this issue, I used netsh to verify the current proxy configuration and to remove it:

Verify and remove winhttp proxy configuration on OS level
Verify and remove winhttp proxy configuration on OS level

Afterwards I did a second connectivity check:

Exchange connectivity check without proxy

Surprise, surprise, the exchange connectivity test was successful. Next, I tried to move a SfB OnPrem user to Teams once again.

Rollback without a proxy works like a charm

And here we go. After disabling the proxy configuration, the migration process could communicate directly with Exchange Web Services and rollback the user’s Unified Contact store successfully. Subsequently, the migration process continued and the user migrated successfully to Microsoft Teams.


Use the Unified Contact Store in Skype for Business

Unified Contact Store by

One Reply to “Roll back error during SfB user migration to Teams”

Leave a Reply

Your email address will not be published. Required fields are marked *