Link to home
Create AccountLog in
Avatar of moeshakir
moeshakirFlag 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.
ASKER CERTIFIED SOLUTION
Avatar of Vasil Michev (MVP)
Vasil Michev (MVP)
Flag of Bulgaria image

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer
Avatar of moeshakir

ASKER

Thanks Vasil. This worked.