Auditing Retention Policies in Office 365
Some companies are required by law to keep customer data for a certain number of years. Other companies need to make sure that customer data is not kept for a long period at all. Luckily Office 365 offers Retention Policies which are applied to users mailboxes and make sure that these compliance requirements are correctly enforced.
But how do you know if your users have the correct Retention Policy applied? With a few easy PowerShell commands you can generate a report that tells you.
To start off, we need to connect to Office 365 using PowerShell.
Then, simply run this command to export a list of all your mailboxes and their retention policy to a CSV file.
Get-Mailbox -ResultSize Unlimited | select DisplayName,UserPrincipalName,RetentionHoldEnabled, RetentionPolicy | Export-CSV UserRetentionPolicy.csv
This will export these details to a CSV file called UserRetentionPolicy.csv in the current directory. You can now open this in Microsoft Excel to see the results.
If you can’t be bothered with all this PowerShell, you could sign up to our Office 365 Reporting application and we can do the hard work for you.