Alteryx Server Knowledge Base

Definitive answers from Server experts.

How To Manually Change A Domain User To New Domain

rkong
Alteryx
Alteryx
Created

How To Manually Change A Domain User To New Domain


It is not uncommon for customers to migrate existing users from an old domain to a new domain. This article explains how to achieve this manually in MongoDB.
 

Prerequisites

  • Alteryx Server
    • Version(s) 2020.1+
  • Robo Studio 3T
 

Procedure


For Windows Authentication, Gallery user is created automatically when logging in the first time. Below is the information Gallery synced from domain AD and stored in the users collection in the AlteryxGallery MongoDB:

Collection users documents <--> AD attributes

Email <--> mail
FirstName <--> givenName
LastName <--> sn
WindowsIdentity.Sid <--> objectSid
WindowsIdentity.DisplayName <--> displayName
WindowsIdentity.Name <--> domain\user format
WindowsIdentity.SamAccountName <--> sAMAccountName

Please refer to https://help.alteryx.com/20221/server/alteryxgallery-mongodb-schema for AlteryxGallery MongoDB schema.

We can update all this information and still keep the unique ObjectId which is used as a "Foreign Key" in other collections to build the relationship between this user and the user's assets in Gallery.

Based on this knowledge, here are detailed steps to change a domain user to the new domain.

1. Connect MongoDB using Robo Studio 3T .
 
2. Browse to AlteryxGallery-->Collection user and find the record of the user we are going to change using this query:
db.getCollection('users').find({'FirstName':'the_first_name_of_the_user','LastName':'the_last_name_of_the_user'})
For example:

db.getCollection('users').find({'FirstName':'Alex','LastName':'A'})


3. Right-click the record and select "Copy Json" and save the content to a notepad.
4. Right-click again and select "Edit Document".
5. Update/verify the value of the following fields:
  • Email
  • FirstName
  • LastName
  • WindowsIdentity.Sid
  • WindowsIdentity.DisplayName
  • WindowsIdentity.Name
  • WindowsIdentity.SamAccountName. 

The correct values should be from the new domain AD.

6. Once the changes are made, click Save at the bottom right.
 

Common Issues

In MongoDB AlteryxGallery, under the most situation, the ObjectId is used to refer to the user. However, if a collection is shared with a domain user for Windows Authentication, then Sid is used instead of ObjectId.

Please run the following query in Robo Studio 3T to find if the old Sid is used for sharing collection.
db.getCollection('collections').find({'Users.ActiveDirectoryObject.Sid':'Old_Sid'})

a. If there are records, please replace this old SID with the new SID.
b. If there are no records, then no further action is required.

 
 


Additional Resources