Avatar of moeshakir
moeshakir
Flag for United States of America asked on

AutoMapping Office 365

I gave full access to all user mailboxes to an admin using the below command through Powershell.

Get-Mailbox -ResultSize unlimited -Filter {(RecipientTypeDetails -eq 'UserMailbox')} | Add-MailboxPermission -User abc@abcd.com -AccessRights FullAccess -InheritanceType all

It ended up crashing the users outlook profile and auto mapping all users.

Is there a command to remove auto mapping without removing mailbox permission?
I also like to know what is the powershell command to completely remove all mailbox permissions?

Will it be this?

Get-Mailbox -ResultSize unlimited -Filter {(RecipientTypeDetails -eq 'UserMailbox')} | Remove-MailboxPermission -User abc@abcd.com -AccessRights FullAccess -InheritanceType all -Automapping $false

Thanks for anyones help.
Microsoft 365Powershell

Avatar of undefined
Last Comment
moeshakir

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Vasil Michev (MVP)

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
moeshakir

ASKER
Thanks Vasil. This worked.
Experts Exchange has (a) saved my job multiple times, (b) saved me hours, days, and even weeks of work, and often (c) makes me look like a superhero! This place is MAGIC!
Walt Forbes