Office365/Exchange Online – Messages are not moving to Archive Mailbox after Applying Retention Policy | Litigation Hold | Retention Hold

|
, | TechPress-KBID-467
Home » Office 365 » Office365/Exchange Online – Messages are not moving to Archive Mailbox after Applying Retention Policy | Litigation Hold | Retention Hold

Recently came across an issue where we had applied the Mailbox Retention Policy for all the users but for some of the users, emails were not getting moved to Online Archive Mailbox. After investigating on this issue, it was identified that the retention hold was enabled on these users mailbox which was not allowing the messages to move to Archive Mailboxes. I have used below commands to check the Retention Hold value for the users and updated this value to fix the issue.

“Placing a mailbox on retention hold suspends the processing of an MRM retention policy by the Managed Folder Assistant for that mailbox. Retention hold is designed for situations such as a user being on vacation or away temporarily. “

First you need to Install and Import the ExchangeOnlineMangement Powershell Module

Install-Module ExchangeOnlineManagement
Import-Module ExchangeOnlineManagement
$UserCredential = Get-Credential
Connect-ExchangeOnline -Credential $UserCredential -ShowProgress $true

Once you are connected to ExchangeOnlineManagement Powershell Module, Then Check the RetentionHoldEnabled property of the mailbox to find out if its enabled or not.

Get-Mailbox "email address" | Select RetentionHoldEnabled

If the RetentionHoldEnabled is true then change it to false to allow archiving for the mailbox as per the Retention Policies configured.

Set-Mailbox "email address" -RetentionHoldEnabled $false

To Check the Retention Policy and Retention Hold Value for all the Mailboxes, Use below command

Get-Mailbox -ResultSize unlimited | Where-Object {$_.RetentionHoldEnabled -eq $true} | Format-Table Name,RetentionPolicy,RetentionHoldEnabled -Auto

Disable Retention Hold Enabled value for all the users.

Get-Mailbox -ResultSize Unlimited -Filter "RecipientTypeDetails -eq 'UserMailbox'" | Set-Mailbox -RetentionHoldEnabled $false

Litigation Hold

For Legal or Compliance Purpose , you can put entire user’s mailbox on Hold, which means that it will preserve mailbox content in the Purges Folder even if the user has deleted the mailbox item. Below diagram shows the sub folders in the Recoverable Items Folders and hold workflow process.

Source: Microsoft

To check if the Litigation Hold is enabled for users, you can use below commands after you are connected to ExchangeOnlineManagement Powershell Module.

Get the list of all the users where Litigation Hold is enabled:

get-mailbox -ResultSize Unlimited | Where-object {$_.LitigationHoldenabled -eq $true} | Select Name, LitigationHoldEnabled,Litigationholdduration

Set the Litigation hold on a user mailbox for 7 Years

set-mailbox "email address" -LitigationHoldEnabled $true -LitigationHoldDuration 2556

Enable the Litigation hold on All the User Mailboxes and Set the Duration to 7 years.

Get-Mailbox -ResultSize Unlimited -Filter "RecipientTypeDetails -eq 'UserMailbox'" | Set-Mailbox -LitigationHoldEnabled $true -LitigationHoldDuration 2556

 

Leave a Reply