question

JussiLehti-7925 avatar image
0 Votes"
JussiLehti-7925 asked JussiLehti-7925 answered

Sharepoint 2019 Hybrid Onedrive - User redirection not working

Just configured Hybrid Onedrive successfully to new Sharepoint 2019 farm and confirmed that the redirection to Sharepoint Online works when clicking on the Onedrive button from the waffle or from top right corner from your profile picture.

But our client has also this site which contains a "phonebook" which is basically a search query webpart that returns users with their name, phonenumber, department etc.

When I click the name of the user from those results, I will go to this url:

 https://domain-my.sharepoint.com/Person.aspx?accountname=DOMAIN\user

...which is the "mysite" location in Sharepoint Online pointing to an accountname where the accountname is in sAMAccountName format.

Okay, so the browser prompts for credentials to login to Sharepoint Online and the user will input their UPN (firstname.lastname@domain.sharepoint.com) and then they will see an error which states that User not found.

Need help asap please.



office-sharepoint-onlineoffice-sharepoint-server-administrationoffice-sharepoint-server-itpro
· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi anonymous user
I am currently looking into this issue and will give you an update as soon as possible.

Thank you for your understanding and support.

1 Vote 1 ·

Forgot to mention that we are using Windows Authentication and I believe the Claim User Identifier is sAMAccountName since the above link points to accountname=DOMAIN\user.

Since the Accountname-property's mapped attribute is <Specific to connection> should I change the Claim User Identifier property mapping to User Principal Name so the Accountname property would be also be mapped to User Principal Name and so it would match the profile in Sharepoint Online?

If yes, what will happen to the existing profiles?

0 Votes 0 ·
YiLu-MSFT avatar image
0 Votes"
YiLu-MSFT answered JussiLehti-7925 edited

Hi anonymous user
This issue is a bit complicated,I cannot reproduce the issue in my end. If you want to get a certain confirmation, I suggest you open a ticket with Microsoft to confirm.


If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

If it helps here's some more details:

So our client is upgrading from SP2013 and only the content db's are being moved with SP2013 -> SP2016 -> SP2019 upgrade path.

They had Hybrid Onedrive configured also in SP2013 and what is weird that they didn't have this problem in SP2013...until it went broken in there at some point in this summer. Not a clue how and why it suddenly didn't work there anymore.

And now I'm struggling with this in SP2019 with Hybrid Onedrive.

Could you confirm that you can reproduce this scenario where you are using Windows authentication in Sharepoint OnPrem so your User Profile accountname is DOMAIN\username and also those person.aspx links are like this: https://domain-my.sharepoint.com/Person.aspx?accountname=DOMAINuser

...and when you click a username (which points to above url) it redirects to Sharepoint Online and prompts for credentials.
After you type your password it goes to you Sharepoint Online User profile ?


0 Votes 0 ·
JussiLehti-7925 avatar image
0 Votes"
JussiLehti-7925 answered

I tried to sync a library from Sharepoint 2019 to Onedrive app in a laptop and there's the same problem.



  1. User has logged in to the laptop with sAMAccountName = DOMAIN\username

  2. Then he logged in to the Onedrive app in the laptop with his O365 account e.g. User Principal Name = firstname.lastname@domain.com

  3. Then he opened Sharepoint 2019 and navigated to a library and clicked Sync

  4. Onedrive throws an error that says something like "Unfortunately couldn't sync the folder. Contact your IT Administrator, if you want to configure Onedrive to sync local SharePoint-folders."

  5. Then user closes that error window and clicked again the Sync button in the library and now Onedrive client prompts for login for the DOMAIN\username. So here we can see the same pattern: It does not recognize the AD-account (DOMAIN\username) and the O365-account (UserPrincipalName) as the same account.

  6. Our client (who manages their O365 environment) has told me that those profiles are cloud synced, but could there be something wrong with their AD Connect or somewhere else than Sharepoint?







5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

JussiLehti-7925 avatar image
0 Votes"
JussiLehti-7925 answered

Found it, apparently you need to config the Onedrive client via registry/gpo before it can work in a Hybrid solution.

https://docs.microsoft.com/en-us/sharepoint/install/new-onedrive-sync-client


Can some tell me why the hell this is not included or even referred in the Configure hybrid Microsoft Onedrive-article ?
https://docs.microsoft.com/en-us/sharepoint/hybrid/configure-hybrid-onedrive-for-business


This took too much hours to solve for such a simple solution that could've been just even referred in that above article that I've read about hundred times now.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.