From 162d727c4d346e6fff915f68cec4688a15019f3e Mon Sep 17 00:00:00 2001 From: Georgi Matev Date: Wed, 15 Mar 2023 14:56:25 -0700 Subject: [PATCH] Seems that Start-ManagedFolderAssistant is not supported on all domains. The setting did not seem to work anyway --- src/cmd/purge/scripts/setRetention.ps1 | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/cmd/purge/scripts/setRetention.ps1 b/src/cmd/purge/scripts/setRetention.ps1 index d50d861ad..51e1b197a 100644 --- a/src/cmd/purge/scripts/setRetention.ps1 +++ b/src/cmd/purge/scripts/setRetention.ps1 @@ -22,5 +22,4 @@ Connect-ExchangeOnline -Credential $cred Write-Host "Resetting retention..." # Set retention values for all mailboxes -Get-Mailbox | ForEach-Object { Set-Mailbox -Identity $_.Alias -RetentionHoldEnabled $false -LitigationHoldEnabled $false -SingleItemRecoveryEnabled $false -RetainDeletedItemsFor 0 -AuditLogAgeLimit 0 -Force } -Get-Mailbox | ForEach-Object { Start-ManagedFolderAssistant -Identity $_.Alias } +Get-Mailbox | ForEach-Object { Set-Mailbox -Identity $_.Alias -RetentionHoldEnabled $false -LitigationHoldEnabled $false -SingleItemRecoveryEnabled $false -RetainDeletedItemsFor 0 -AuditLogAgeLimit 0 -Force } \ No newline at end of file