Create a retention policy for Exchange Online

In Exchange Online, you can use messaging records management (MRM) retention policies to manage the email lifecycle. Retention policies are applied by creating retention tags, adding them to a retention policy, and applying the policy to mailbox users.

For additional management tasks related to retention policies, see Management Procedures of messaging logs.

What do you need to know before you begin?

  • Estimated time to complete this task: 30 minutes.

  • The procedures in this topic require specific permissions. See the permissions information for each procedure.

  • Settings for MRM retention labels and policies are located on the Microsoft Purview compliance portal.

  • The mailboxes to which you apply these retention policies must reside in Microsoft 365.

Step 1: Create a retention label

You must be assigned permissions before you can perform this procedure or procedures. To see what permissions you need, see the “Messaging log management” entry in the Feature permissions in Exchange Online topic.

Use the Purview compliance portal to create a retention label

    <li

    Sign in to the Microsoft Purview Compliance Portal and go to Solutions > Data Lifecycle Management > Exchange (legacy) > MRM Retention Tags, and then select + New Tag.

  1. Under Define how the tag will be applied. strong>, select one of the following options, and then select Next:

    • Automatically to entire mailbox (default) : select this option to create a default policy tag (DPT). You can use DPTs to create a default deletion policy and a default archive policy, which is applied to all mailbox items.

      You can’t use this setting to create a DPT to delete mail items from voice. For details on how to create a DPT to delete voicemail items, see the Exchange Online PowerShell example on this page.

    • Automatically to default folder – Select this option to create a retention policy tag (RPT) for a default folder, such as Inbox or Deleted Items, and then select the folder .

      You can create RPTs only with the hold actions Delete and allow recovery or Delete permanently.

    • By Users to Items and Folders (Personal): Select this option to create personal tags. These labels allow users of Outlook and Outlook on the web (formerly known as Outlook Web App or OWA) to apply archiving or deletion settings to a message or folders that are different from the settings applied to the parent folder or the entire mailbox .

  2. On the Define Retention Settings page, the title and options will vary depending on the type of tag you have selected. Complete the following fields, then select Next:

    • Retention Period: Select one of the following options:

      • When item reaches next age (in days): Select this option and specify the number of days to keep items before moving or deleting them. The retention age for all supported items except Calendar and Tasks is calculated from the date an item is received or created. The retention age for Calendar and Tasks items is calculated from the end date.

      • Never: Select this option to specify that items should never be removed or moved. to the file.

    • Hold Action: Select one of the following actions to take after the item reaches its retention period:

      • Delete and Allow Retrieval – Select this action to delete items but allow users to retrieve them using Recover deleted items. strong> option in Outlook or Outlook on the web. Items are retained until the deleted item retention period configured for the mailbox database or mailbox user is reached.

      • Delete Permanently – Select this option to permanently delete the item from the mailbox database.

      • Move item to archive – This action is only available if you are creating a DPT or personal tag. Select this action to move items to the user’s archive mailbox.

  3. Under Name your label page, enter a name and optional description, and then select Next:

    • Name: Enter a name for the retention label. The tag name is for display purposes and has no impact on the folder or item to which a tag is applied. Note that the personal tags that you provide to users are available in Outlook and Outlook on the web.

    • Description: Use this optional field to enter administrative notes or comments. The field is not displayed to users.

  4. Review and submit to create the label with the chosen settings.

See Also:  How to create push notifications from a wordpress website

Use Exchange Online PowerShell to create a retention tag

Use the New-RetentionPolicyTag cmdlet to create a retention tag. The different options available in the cmdlet allow you to create different types of retention tags. Use the Type parameter to create a DPT (value of All), RPT (specify a default folder type, such as Inbox), or a personal tag (value of Personal).

The following example creates a DPT to delete all messages in the mailbox after 7 years (2556 days):

New-RetentionPolicyTag -Name “DPT -Corp-Delete ” -Type All -AgeLimitForRetention 2556 -RetentionAction DeleteAndAllowRecovery

The following example creates a DPT to move all messages to the local archive in 2 years (730 days):

New-RetentionPolicyTag -Name “DPT -Corp -Move” -Type All -AgeLimitForRetention 730 -RetentionAction MoveToArchive

The following example creates a DPT to delete voicemail messages after 20 days:

New-RetentionPolicyTag -Name “DPT-Corp-Voicemail ” -Type All – MessageClass Voicemail -AgeLimitForRetention 20 -RetentionAction DeleteAndAllowRecovery

The following example creates an RPT to delete Permanently put messages in the Junk Email folder after 30 days. ys:

New-RetentionPolicyTag -Name “RPT-Corp-JunkMail” -Type JunkEmail -AgeLimitForRetention 30 -RetentionAction PermanentlyDelete

The following example creates a personal tag to never delete a message:

New-RetentionPolicyTag -Name “Never delete” -Type Personal -RetentionAction DeleteAndAllowRecovery -RetentionEnabled $false

Step 2: Create a retention policy

You must be assigned permissions before you can perform this procedure or procedures. To see what permissions you need, see the “Messaging log management” entry in the Feature permissions in Exchange Online topic.

See Also:  Top Tips to Start a Network Marketing Blog

Use the Microsoft Purview compliance portal to create a retention policy

  1. Sign in to the Microsoft Purview Compliance Portal and go to Solutions > Data Lifecycle Management > Exchange (Legacy) > MRM Retention Policies and then select New Policy.

  2. In On the Set Up Your Policy page, enter a name for the retention policy, and then select + Add Tag to select the tags you want to add to this retention policy.

    You can create a retention policy without adding any retention tags, but the mailbox items to which the policy applies won’t be moved or deleted. You can also add and remove retention tags from a retention policy after you create it.

  3. On the Choose Retention Tags page, select the tags that desired, and then select Add.

    A retention policy can contain the following tags:

    • A DPT with Move item to archive action.

    • A DPT with the actions Delete and allow recovery or Delete permanently strong>.

    • A DPT for voicemail messages with the actions Delete and allow recovery or Delete permanently .

    • One RPT per default folder, such as Inbox to delete items.

    • Any number of personal tags.

  4. Review and submit to create your retention policy with your confi igurations.

You can create a retention policy without adding any retention tags to it, but items in the mailbox to which the policy is applied will not be moved or deleted . You can also add and remove retention tags from a retention policy after you create it.

See Also:  How to create an iphone app layout in photoshop

Use Exchange Online PowerShell to create a retention policy

The following example creates the retention policy RetentionPolicy -Corp and uses the RetentionPolicyTagLinks parameter to associate five retention tags with the policy:

New-RetentionPolicy “RetentionPolicy-Corp” -RetentionPolicyTagLinks “DPT-Corp-Delete”,”DPT-Corp-Move”,”DPT- Corp-Voicemail” ,”RPT-Corp-JunkMail”,”Never Delete”

For detailed syntax and parameter information, see New-RetentionPolicy.

Step 3: Apply a policy retention to mailbox users

After you create a retention policy, you must apply it to mailbox users. You can apply different retention policies to different sets of users. For detailed instructions, see Apply a retention policy to mailboxes.

How do you know this worked?

After you create retention tags, add them to a retention policy, and apply the policy to a mailbox user, the next time the wizard When MRM mailbox processes the mailbox, messages are moved or deleted based on the settings you configured in the retention labels.

To verify that you have applied the retention policy, do the following:

  1. Replace with the name, email address, or alias of the mailbox and run the following command in Exchange Online PowerShell to manually run the MRM wizard on a single mailbox:

    Start-ManagedFolderAssistant: Identity “”

  2. Log in to the mailbox using Outlook or Outlook on the web and verify that messages are deleted or moved to an archive file. according to the policy setting.

.

Leave a Reply

Your email address will not be published. Required fields are marked *