Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.
PS C:\Windows\system32> LaunchEMS
# 既定のリテンションポリシー
[PS] C:\Windows\system32> Get-RetentionPolicy
Name RetentionPolicyTagLinks Guid
---- ----------------------- ----
Default MRM Policy {Recoverable Items 14 days move to 51852c1f-4b00-4cdf-9332-7e8ab8bc5b2a
archive, Never Delete, 5 Year
Delete, 1 Year Delete, 6 Month
Delete, 1 Month Delete, 1 Week
Delete, Personal never move to
archive, Personal 5 year move to
archive, Default 2 year move to
archive, Personal 1 year move to
archive}
ArbitrationMailbox {Never Delete, 440df3a5-6e09-4808-adb1-59c90dff4b66
AsyncOperationNotification,
ModeratedRecipients, AutoGroup}
# 既定のリテンションポリシータグ
[PS] C:\Windows\system32> Get-RetentionPolicyTag | Format-Table -AutoSize -Wrap
Name Type Description
---- ---- -----------
Personal 1 year move to archive Personal Managed Content Settings
Default 2 year move to archive All Managed Content Settings
Personal 5 year move to archive Personal Managed Content Settings
Personal never move to archive Personal Managed Content Settings
1 Week Delete Personal Managed Content Settings
1 Month Delete Personal Managed Content Settings
6 Month Delete Personal Managed Content Settings
1 Year Delete Personal Managed Content Settings
5 Year Delete Personal Managed Content Settings
Never Delete Personal Managed Content Settings
Recoverable Items 14 days move to archive RecoverableItems Managed Content Settings
# 既定では リテンションポリシーは適用されないが
# インプレースアーカイブを有効にしたユーザーには 既定のリテンションポリシーが自動的に適用される
[PS] C:\Windows\system32> Get-Mailbox "Suse" | Select Name,ArchiveDatabase,RetentionPolicy
Name ArchiveDatabase RetentionPolicy
---- --------------- ---------------
Suse Linux
[PS] C:\Windows\system32> Get-Mailbox "Centos" | Select Name,ArchiveDatabase,RetentionPolicy
Name ArchiveDatabase RetentionPolicy
---- --------------- ---------------
CentOS Linux Archive Database 001 Default MRM Policy
# リテンションポリシーを新規作成して適用する場合は以下
# リテンションポリシータグ新規作成
# * 各パラメーターの意味は [Get-Help New-RetentionPolicyTag -Full] 参照
[PS] C:\Windows\system32> New-RetentionPolicyTag -Name "2 Year Delete" -Type All -AgeLimitForRetention 730 -RetentionAction DeleteAndAllowRecovery
[PS] C:\Windows\system32> New-RetentionPolicyTag -Name "3 Month move to Archive" -Type All -AgeLimitForRetention 90 -RetentionAction MoveToArchive
# リテンションポリシーを新規作成して 作成済みのリテンションポリシータグをリンク
# * 各パラメーターの意味は [Get-Help New-RetentionPolicy -Full] 参照
# * 複数タグをリンクする場合はカンマ区切りで指定
[PS] C:\Windows\system32> New-RetentionPolicy "My Delete Policy" -RetentionPolicyTagLinks "2 Year Delete"
[PS] C:\Windows\system32> New-RetentionPolicy "My Archive Policy" -RetentionPolicyTagLinks "3 Month move to Archive"
[PS] C:\Windows\system32> Get-RetentionPolicy
Name RetentionPolicyTagLinks Guid
---- ----------------------- ----
Default MRM Policy {Recoverable Items 14 days move to 51852c1f-4b00-4cdf-9332-7e8ab8bc5b2a
archive, Never Delete, 5 Year
Delete, 1 Year Delete, 6 Month
Delete, 1 Month Delete, 1 Week
Delete, Personal never move to
archive, Personal 5 year move to
archive, Default 2 year move to
archive, Personal 1 year move to
archive}
ArbitrationMailbox {Never Delete, 440df3a5-6e09-4808-adb1-59c90dff4b66
AsyncOperationNotification,
ModeratedRecipients, AutoGroup}
My Delete Policy {2 Year Delete} 71f052a6-ace9-4e81-a79a-4d2cabd202c6
My Archive Policy {3 Month move to Archive} e2836c60-b234-474d-b8d6-8434ddc8f04c
[PS] C:\Windows\system32> Get-RetentionPolicyTag | Format-Table -AutoSize -Wrap
Name Type Description
---- ---- -----------
Personal 1 year move to archive Personal Managed Content Settings
Default 2 year move to archive All Managed Content Settings
Personal 5 year move to archive Personal Managed Content Settings
Personal never move to archive Personal Managed Content Settings
1 Week Delete Personal Managed Content Settings
1 Month Delete Personal Managed Content Settings
6 Month Delete Personal Managed Content Settings
1 Year Delete Personal Managed Content Settings
5 Year Delete Personal Managed Content Settings
Never Delete Personal Managed Content Settings
Recoverable Items 14 days move to archive RecoverableItems Managed Content Settings
2 Year Delete All Managed Content Settings
3 Month move to Archive All Managed Content Settings
# リテンションポリシーを設定したい各ユーザーにポリシーを設定
[PS] C:\Windows\system32> Set-Mailbox "Debian" -RetentionPolicy "My Delete Policy"
[PS] C:\Windows\system32> Start-ManagedFolderAssistant -Identity "Debian"
[PS] C:\Windows\system32> Set-Mailbox "Ubuntu" -RetentionPolicy "My Archive Policy"
[PS] C:\Windows\system32> Start-ManagedFolderAssistant -Identity "Ubuntu"
[PS] C:\Windows\system32> Get-Mailbox -Filter "Name -NotLike 'DiscoverySearchMailbox*'" | Select Name,ArchiveDatabase,RetentionPolicy
Name ArchiveDatabase RetentionPolicy
---- --------------- ---------------
CentOS Linux Archive Database 001 Default MRM Policy
Debian Linux My Delete Policy
Exchange Admin
Fedora Linux
RedHat Linux
Server World Archive Database 001 Default MRM Policy
Suse Linux
Ubuntu Linux Archive Database 001 My Archive Policy
|