Forum Discussion

Marvin Oco's avatar
Marvin Oco
Steel Contributor
Aug 11, 2017
Solved

enable litigation hold via power shell

we use script below to enable litigation hold to all users, is there a script where we can just target enabling disabled users without going through all users? ********************* Get-Mailb...
  • you can try this script

     

    Get-Mailbox -ResultSize Unlimited -Filter {RecipientTypeDetails -eq "UserMailbox"} | Where-Object { $_.LitigationHoldEnabled -eq $False } | Set-Mailbox -LitigationHoldEnabled $true -LitigationHoldDuration 5475