
Lastly, run we will run an Azure AD Connect manual sync to connect the accounts. Set-MsolUser -UserPrincipalName -ImmutableID “paste ObjectGUID here” Once connected, run the Set-MsolUser command to set the recently exported objectGUID as the ImmutableID for the user. Navigate back to Powershell and run the Connect-MsolService command to connect to Azure Active Directory. Ldifde -d “paste distinguishedName here” -f C:\User1.txtĪfter the command has completed, open the output text file and locate the objectGUID. Paste the distinguishedName value in between the parentheses. Open PowerShell and run the below command. Once we have the distinguishedName, we will use LDIFDE commands to export the users objectGUID. Next, from the Attribute Editor tab, locate and copy the distinguishedName value. Navigate to Active Directory and locate the recently restored user. Now that the user has been restored, we will match the AD account with the cloud account, so there is no mismatch during the next synchronization. In our case, we are going to restore the object directly back to the AD server. Right-click the user and choose the location for restore.

Once you click Finish, the restore point will be mounted.Īfter the point has mounted, locate the pertinent user from the Active Directory database. Next, select the restore point where the AD user was still active. Right-click the server and select Microsoft Active Directory Objects from the Restore Application Items option. To begin, log into the Veeam console and locate your Active Directory server from Disk Backups. Therefore, we will restore the AD object from Veeam. Restore Active Directory User from VeeamĪs mentioned early, this environment didn’t have the Active Directory Recycling bin enabled.

Next, we will restore the user in Active Directory. Looking at the restored user, we can see they are Active and their Sync status is In Cloud.

Next, choose to auto-generate or manually create a password. Select the pertinent user and click Restore. To begin, navigate to the Microsoft 365 Admin Center. In our case, we will restore the Active Directory object from Veeam as the environment did not have the AD recycle bin enabled. The process isn’t overly intensive – It entails restoring the deleted user in Office 365, restoring the Active Directory account, and performing a hard match between the on-prem and cloud account. In this post, we will walk through the process of restoring a deleted user in an environment that leverages Directory Sync/Azure AD Connect.
