I ran into an issue during a 365 tenant-to-tenant migration that had me stumped at first. I needed to remove the vanity domain from the source tenant and I was down to a couple AD-synced users and group objects that said they still used the vanity domain. Odd thing was, those objects didn’t exist in AD or were in OUs that aren’t configured to sync.
I tried a bunch of stuff but ultimately found a solution.
To remove the users, I just went to Azure AD -> Users and deleted the users and it allowed me (even though they said they were synced from AD!)
I tried removing the groups in the same way but it doesn’t give you a delete option in the Azure portal so I did it via PowerShell instead. Run the first command to get the group ID of the group you want to delete and run the second command to actually delete it.
Get-MsolGroup Remove-MsolGroup -ObjectID "(Group ID)" -Force
Jason works as a project specialist at an IT MSP in Pennsylvania, USA. He’s an IT/security professional with 20 years experience.