Quantcast
Channel: Exchange Server 2013 - Administration, Monitoring, and Performance forum
Viewing all articles
Browse latest Browse all 9032

exclude mailbox from retention policy 2010

$
0
0

I have a scheduled job which runs daily and applies a Mailbox Retention Policy to any new mailboxes created. 

The schedule jobs runs this script.   I am trying to exclude a mailbox from this policy. Help please.

function Load_Exchange_Tools {

               if (-not (Get-pssnapin | ? {$_.name -like 'Microsoft.Exchange.Management.PowerShell.e2010'})) {

                              Add-PSSnapin Microsoft.Exchange.Management.PowerShell.e2010

              }

}

Load_Exchange_Tools

Get-Mailbox -Filter {CustomAttribute1 -ne "LITHOLD"} -ResultSize Unlimited | Set-Mailbox -RetentionPolicy "Company Mailbox Policy"


Viewing all articles
Browse latest Browse all 9032

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>