Feb 19 2020
12:50 AM
- last edited on
Feb 07 2023
07:59 PM
by
TechCommunityAP
Feb 19 2020
12:50 AM
- last edited on
Feb 07 2023
07:59 PM
by
TechCommunityAP
Dear community,
if we deactivate users that we originally synchronized from our on premise ad and take away their license, they keep their email address in the mail attribute.
Can anyone tell me how to set the attribute to null?
Best regards
Sascha
Feb 19 2020 07:02 AM
If this object is synchronized from your AD and has an old on-premise exchange account and you just want to provision a new cloud mailbox.
Clear the following attributes then force a sync.
1. MsExchMailboxGuid
2. MsExchRecipientDisplayType
3. MsExchRecipientTypeDetails
Feb 19 2020 07:06 AM
Feb 19 2020 09:24 AM
Generally speaking, you cannot. You can try the method detailed here: https://techcommunity.microsoft.com/t5/exchange-team-blog/permanently-clear-previous-mailbox-info/ba...
Or here, depending on the situation: https://www.michev.info/Blog/Post/2388/permanently-disable-a-mailbox-in-office-365
Feb 19 2020 09:27 AM
Oh, I see. You just want to clear the mail attributes as you already have removed the licenses. I haven't tried to do so but maybe you can use the Remove-Mailbox cmdlet? Thank you!
Feb 27 2020 12:12 AM
@Vasil Michev Unfortunately, it didn't help. Thanks anyway for your tips.
Jul 30 2021 03:00 AM
May 02 2022 05:15 AM
Get-ADUser -Identity "SAMAccountName" | Set-ADUser -EmailAddress ""
Are you using a PowerShell termination script or manually performing your offboarding?
May 02 2022 05:52 AM
@ChrissyN We did the offboarding manually. The commands you posted are for on premise AD. So I think they cannot be used for the cloud accounts.