Created
March 12, 2020 18:49
-
-
Save mobernberger/6194298bbb2087a0295214e52497c869 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Connect to Exchange Online Powershell before running this commands. | |
$Mbx = Get-Mailbox -RecipientTypeDetails UserMailbox, SharedMailbox -ResultSize Unlimited | Select DistinguishedName, DisplayName | |
ForEach ($M in $Mbx) { | |
Write-Host "Manually enabling mailbox auditing for" $M.DisplayName | |
Set-Mailbox -Identity $M.DistinguishedName -AuditEnabled $True } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment