We have an issue with SharePoint 2016 on 2 accounts created in AD. We have 2 users, i.e. user1 and user2 which have been created in AD and sync to the SharePoint. After a while, the 2 account name have been swapped in AD so the AD accounts ended up like:
- user1 -> user2
- user2 -> user1
We found that SharePoint seems to confuse the 2 users and when user2 (originally user1) login, the SharePoint seems to think that user1 is logged and some of our custom webparts did not work because it failed to map the correct user. SharePoint returned the login name of the user2 is i:0#.w|domain\user1 instead of the supposed i:0#.w|domain\user2. Are there anyways to fix these 2 accounts? Thanks
Update: We found a strange behaviour with the user profile for user1 and user2. After we did a user profile import from AD, the user profile is able to show in the User Profile Application in Central Admin. Then after the User Profile to SharePoint Full Synchronization timer jobs has run, the profile become corrupted, i.e. the user2 email became empty (which was not in AD and before the sync job) and user1 disappear completely from the user profile. We suspect there is something wrong with the SPUser objects for user1 and user2 in all the site collections but we do not know how to check or confirm.