Enterprise Vault™ PowerShell Cmdlets

Last Published:
Product(s): Enterprise Vault (12.4)
  1. Introducing the Enterprise Vault PowerShell cmdlets
    1.  
      About the Enterprise Vault Management Shell
    2.  
      Getting Help for Enterprise Vault PowerShell cmdlets
    3.  
      Rules for PowerShell strings
    4. Where to get more information about Enterprise Vault
      1.  
        Enterprise Vault training modules
  2. Archiving: Exchange
    1.  
      Add-EVPstComputer
    2.  
      Add-EVPstFile
    3.  
      Get-EVExchangeMailboxPolicy
    4.  
      New-EVExchangeMailboxPolicy
    5.  
      Remove-EVExchangeFolderPolicy
    6.  
      Remove-EVExchangeMailboxPolicy
    7.  
      Set-EVExchangeMailboxPolicy
  3. Archiving: FSA
    1.  
      Get-EVFSAComputerSettings
    2.  
      Get-EVFSAFileServer
    3.  
      Get-EVFSAFolder
    4.  
      Get-EVFSASiteSettings
    5.  
      Get-EVFSAVolume
    6.  
      New-EVFSAFileServer
    7.  
      New-EVFSAFolder
    8.  
      New-EVFSAVolume
    9.  
      Remove-EVFSAFileServer
    10.  
      Remove-EVFSAFolder
    11.  
      Remove-EVFSAVolume
    12.  
      Set-EVFSAComputerSettings
    13.  
      Set-EVFSAFileServer
    14.  
      Set-EVFSAFolder
    15.  
      Set-EVFSASiteSettings
    16.  
      Set-EVFSAVolume
  4. Archiving: Skype for Business
    1.  
      Get-EVSkypeForBusinessTarget
    2.  
      New-EVSkypeForBusinessTarget
    3.  
      Remove-EVSkypeForBusinessTarget
    4.  
      Set-EVSkypeForBusinessTarget
  5. Archiving: SMTP
    1.  
      Get-EVSMTPHoldingFolder
    2.  
      Get-EVSMTPMessageTrackingLogLocation
    3.  
      Get-EVSMTPPolicy
    4.  
      Get-EVSMTPServerSettings
    5.  
      Get-EVSMTPTarget
    6.  
      New-EVSMTPPolicy
    7.  
      New-EVSMTPServerSettings
    8.  
      New-EVSMTPTarget
    9.  
      Remove-EVSMTPPolicy
    10.  
      Remove-EVSMTPTarget
    11.  
      Set-EVSMTPMessageTrackingLogLocation
    12.  
      Set-EVSMTPPolicy
    13.  
      Set-EVSMTPServerSettings
    14.  
      Set-EVSMTPTarget
    15.  
      Sync-EVSMTPServerSettings
  6. Backup
    1.  
      Clear-IndexLocationBackupMode
    2.  
      Clear-VaultStoreBackupMode
    3.  
      Get-IndexLocationBackupMode
    4.  
      Get-VaultStoreBackupMode
    5.  
      Set-IndexLocationBackupMode
    6.  
      Set-VaultStoreBackupMode
  7. Classification
    1.  
      Disable-EVClassification
    2.  
      Get-EVClassificationFCITags
    3.  
      Get-EVClassificationPolicy
    4.  
      Get-EVClassificationStatus
    5.  
      Get-EVClassificationTestMode
    6.  
      Get-EVClassificationVICTags
    7.  
      Import-EVClassificationFCIRules
    8.  
      Initialize-EVClassificationVIC
    9.  
      New-EVClassificationPolicy
    10.  
      Publish-EVClassificationFCIRules
    11.  
      Remove-EVClassificationPolicy
    12.  
      Set-EVClassificationPolicy
    13.  
      Set-EVClassificationTestMode
  8. Databases
    1.  
      Get-EVDatabase
    2.  
      Get-EVDatabaseDetail
    3.  
      Get-EVDatabaseFileInfo
    4.  
      Get-EVStorageDatabase
    5.  
      Set-EVDatabaseDetail
    6.  
      Start-EVDatabaseUpgrade
  9. IMAP access
    1.  
      Get-EVIMAPUsers
    2.  
      Get-EVIMAPUserSettings
    3.  
      Set-EVIMAPServerDisabled
    4.  
      Set-EVIMAPServerEnabled
  10. Indexing
    1.  
      Get-EVIndexLocation
    2.  
      Get-EVMDSStatus
    3.  
      Get-IndexServerForIndexLocation
    4.  
      New-EVMDSBuildTask
    5.  
      Set-IndexMetadataSyncLevel
  11. Records management
    1.  
      Export-EVNARAArchive
    2.  
      Get-EVRecordSettings
  12. Retention plans
    1.  
      Get-EVRetentionPlan
    2.  
      New-EVRetentionPlan
    3.  
      Remove-EVRetentionPlan
    4.  
      Set-EVRetentionPlan
  13. Roles-based administration
    1.  
      Add-EVRBARoleMember
    2.  
      Get-EVRBAAzStoreXml
    3.  
      Get-EVRBARole
    4.  
      Get-EVRBARoleMember
    5.  
      Remove-EVRBARoleMember
    6.  
      Set-EVRBAAzStoreXml
  14. Sites and servers
    1.  
      Get-EVComputers
    2.  
      Get-EVFileLocation
    3.  
      Get-EVIISWebsite
    4.  
      Get-EVServer
    5.  
      Get-EVSite
    6.  
      Get-EVSiteInfo
  15. Tasks and services
    1.  
      Get-EVDependencyService
    2.  
      Get-EVDependencyServiceState
    3.  
      Get-EVService
    4.  
      Get-EVServiceState
    5.  
      Get-EVTask
    6.  
      Get-EVTaskState
  16. Vault stores and archives
    1.  
      Export-EVArchive
    2.  
      Get-EVArchive
    3.  
      Get-EVArchivePermission
    4.  
      Get-EVVaultStore
    5.  
      Get-EVVaultStorePartition
    6.  
      Remove-EVArchive
    7.  
      Remove-EVArchivePermission
    8.  
      Set-EVArchive
    9.  
      Set-EVArchivePermission
    10.  
      Start-PartitionRollover

Set-EVRetentionPlan

Set-EVRetentionPlan sets or updates the properties of an existing retention plan, such as its description and associated retention category, classification policy, and retention folders.

If you change any of the retention plan settings, you must run the appropriate provisioning task or restart the appropriate archiving task to apply the changes to the target archives. For example, if you have associated the retention plan with the archive of an SMTP target, you must restart the SMTP Archiving task. In Exchange environments, you must restart the Exchange Mailbox Archiving task and also synchronize the mailboxes.

Set-EVRetentionPlan is provided by the snap-in Symantec.EnterpriseVault.PowerShell.AdminAPI.dll.

Syntax

Set-EVRetentionPlan -SiteId <String> -Name <String> [-Description <String>] [-RetentionCategory <String>] [-OverrideRetention [<SwitchParameter>]] [-ClassificationPolicy <String>] [-FolderXmlPath <String>] [-DisableStorageExpiry [<SwitchParameter>]] [<CommonParameters>]

Set-EVRetentionPlan -SiteId <String> -Name <String> [-Description <String>] [-RetentionCategory <String>] [-OverrideRetention [<SwitchParameter>]] [-ClassificationPolicy <String>] [-FolderXml <String>] [-DisableStorageExpiry [<SwitchParameter>]] [<CommonParameters>]

Parameters

Table: Set-EVRetentionPlan parameters

Parameter

Description

-SiteId (required)

The ID of the Enterprise Vault site for which to set or update the retention plan details. If you omit this parameter, and the cmdlet cannot determine the ID by looking in the registry, then Set-EVRetentionPlan prompts you to enter the required ID.

You can use Get-EVSite to obtain the site ID.

-Name (required)

The name of a specific retention plan whose properties you want to set or update.

-Description

The description to set for the retention plan. The description can contain up to 127 alphanumeric, space, or special characters.

-RetentionCategory

The name of a retention category with which to associate the retention plan.

-OverrideRetention

Add this parameter to override the current retention categories of the affected items with the retention category associated with this plan.

Note:

Omit this parameter if you have also associated the plan with a classification policy that allows the classification rules to update the retention categories of items. In this case, Enterprise Vault expires the items according to the retention categories that the classification rules apply to them.

-ClassificationPolicy

The name of a classification policy with which to associate the retention plan. If specified, Enterprise Vault sends for classification all the archived items that have this retention plan and tags them according to the rules specified in the classification policy.

Note:

Classification operates in test mode if you have yet to install a license for the Enterprise Vault retention feature, or the existing license has expired. Instead of applying classification tags and other changes to the archived items, the classification feature generates a report that lists the planned changes.

-FolderXmlPath

The path to an XML file that defines the properties of one or more retention folders. You can create new retention folders and update or delete existing ones. For more information on retention folders and guidelines on how to prepare the required XML file, see the Administrator's Guide.

Enterprise Vault comes with a sample XML file, RetentionFoldersSample.xml, which you can copy and modify as required. The file is in the Modules\EnterpriseVault subfolder of the Enterprise Vault installation folder (for example, C:\Program Files (x86)\Enterprise Vault\Modules\EnterpriseVault).

If you have associated this retention plan with a classification policy that allows the classification feature to update the retention categories of individual items, the retention folders must have an Expiry setting of Item (not Folder).

Type an absolute, relative, or UNC path, and enclose it in quotation marks if it contains space characters.

-FolderXml

This parameter performs the same function as the -FolderXmlPath parameter. However, in this case you define the retention folder properties in an XML string that you append to the parameter, instead of defining them in an external file. You can create new retention folders and update or delete existing ones.

Use a backtick character (') to escape the quotation marks in this string.

-DisableStorageExpiry

Add this parameter to disable Storage Expiry in any archive that has retention folder issues.

Examples
  • Set-EVRetentionPlan -SiteId 13E...localdomain.com -Name "Projects Retention Plan" -Description "Plan created for managing projects" -RetentionCategory "5 years"

    Updates the properties of an existing retention plan, "Projects Retention Plan", in the specified Enterprise Vault site. The plan has the description "Plan created for managing projects" and the retention category "5 years".

  • Set-EVRetentionPlan -Name "Projects Retention Plan" -ClassificationPolicy CP

    Updates the classification policy property of the specified retention plan.

  • Set-EVRetentionPlan -Name "Projects Retention Plan" -ClassificationPolicy CP -OverrideRetention

    Sets the override retention flag for the specified retention plan. When items are manually deleted or automatically expired, the retention category that you have set with the plan overrides their current retention categories. However, if the classification policy allows classification to update the retention categories of individual items, it is necessary to omit the -OverrideRetention parameter. Enterprise Vault expires the items according to the retention categories that the classification rules apply to them.

  • Set-EVRetentionPlan -SiteId 13E9...localdomain.com -Name "Projects Retention Plan" -Description "Plan updated for managing projects" -RetentionCategory "6 years" -OverrideRetention -ClassificationPolicy CP2

    Updates the properties of an existing retention plan that is named "Projects Retention Plan" in the specified Enterprise Vault site. The plan has the description "Plan updated for managing projects" and the retention category "6 years".

  • Set-EVRetentionPlan -SiteId 13E...localdomain.com -Name "Projects Retention Plan" -ClassificationPolicy ''

    Removes the previously-applied classification policy so that classification no longer occurs.

  • Set-EVRetentionPlan -Name "Projects Retention Plan" -FolderXmlPath c:\RetentionFolders.xml -DisableStorageExpiry

    Applies the retention folder changes that are defined in the file c:\RetentionFolders.xml to the retention plan "Projects Retention Plan". The command also disables Storage Expiry in any archive that has retention folder issues.

    For example, suppose that you originally defined the retention folder settings with the following XML:

    <?xml version="1.0" encoding="utf-16"?>
    <RetentionFolderRoot>
      <RetentionFolder Name="Inbox" RetentionCategory="1 Year"
        Expiry="Item" Inheritance="ThisFolderOnly" />
      <RetentionFolder Name="Business" RetentionCategory="5 Years"
        Expiry="Item" Inheritance="ThisFolderOnly" />
    </RetentionFolderRoot>

    To delete the "Inbox" folder, change the retention category for the "Business" folder to "1 Year", and create a new folder "Unit" as a subfolder of the "Business" folder, save the following as c:\RetentionFolders.xml and then submit it with the above command:

    <?xml version="1.0" encoding="utf-16"?>
    <RetentionFolderRoot>
      <RetentionFolder Name="Business" RetentionCategory="1 Year"
        Expiry="Item" Inheritance="ThisFolderOnly">
        <RetentionFolder Name="Unit" RetentionCategory="5 Years"
          Expiry="Item" Inheritance="ThisFolderAndAllSubfolders" />
      </RetentionFolder>
    </RetentionFolderRoot>

    You can use the following command to return the retention folder information for the plan:

    Get-EVRetentionPlan -Name "New Projects Plan" | select -expand Folders | sort FolderPath | ft -AutoSize

    This command produces the following output:

    FolderPath       FolderName   RetentionCategory   Expiry                Inheritance
    ----------       ----------   -----------------   ------                -----------
    \Business        Business     1 year              Item               ThisFolderOnly
    \Business\Unit   Unit         5 years             Item   ThisFolderAndAllSubfolders
  • Set-EVRetentionPlan -Name "Projects Retention Plan" -FolderXml "<?xml version='"1.0'" encoding='"utf-16'"?><RetentionFolderRoot><RetentionFolder Name='"Business'" RetentionCategory='"1 Year'" Expiry='"Item'" Inheritance='"ThisFolderOnly'"><RetentionFolder Name='"Unit'" RetentionCategory='"5 Years'" Expiry='"Item'" Inheritance='"ThisFolderAndAllSubfolders'" /></RetentionFolder></RetentionFolderRoot>" -DisableStorageExpiry

    Performs the same function as the command in the preceding example. However, the retention folder changes are now defined in the XML string that is appended to the command instead of being defined in an XML file.

  • Set-EVRetentionPlan -Name "New Projects Plan" -FolderXmlPath C:\RetentionFolders.xml

    Applies the retention folder changes that are defined in the file c:\RetentionFolders.xml to the retention plan "Projects Retention Plan". You can use this command to supply alternative names in other languages for the retention folders that you have previously created. For example, suppose that you originally defined the retention folder settings with the following XML:

    <?xml version="1.0" encoding="utf-16"?>
    <RetentionFolderRoot>
    	<RetentionFolder Name="Business" RetentionCategory="1 Year"
    		Expiry="Item" Inheritance="ThisFolderOnly" />
    	<RetentionFolder Name="Unit" RetentionCategory="5 Years"
    		Expiry="Item" Inheritance="ThisFolderOnly" />
    </RetentionFolderRoot>

    By saving the following as C:\RetentionFolders.xml and then submitting it with the above command, you can supply alternative folder names for your Danish users:

    <?xml version="1.0" encoding="utf-16"?>
    <RetentionFolderRoot>
      <Languages>
        <Language>DA-DK</Language>
      </Languages>
      <RetentionFolder Name="Business" RetentionCategory="1 Year"
        Expiry="Item" Inheritance="ThisFolderOnly">
        <Name lang="DA-DK">Forretning</Name>
      </RetentionFolder>
      <RetentionFolder Name="Unit" RetentionCategory="5 Years"
        Expiry="Item" Inheritance="ThisFolderOnly">
        <Name lang="DA-DK">Enhed</Name>
      </RetentionFolder>
    </RetentionFolderRoot>

    The <Languages> node specifies the languages in which you want to supply the alternative folder names ("DA-DK" for Danish in this example). Within each <RetentionFolder> node, you can then enter the alternative folder names ("Forretning" for "Business" and "Enhed" for "Unit").

    See the Administrator's Guide for more information on supplying alternative names of retention folders in multiple languages.

Output

Table: Set-EVRetentionPlan properties lists the properties that are available.

Table: Set-EVRetentionPlan properties

Name

Type

Description

Name

String

The name of the retention plan.

Description

String

The description of the retention plan.

RetentionCategory

String

The name of the retention category that is associated with the retention plan.

OverrideRetention

SwitchParameter

Whether you have specified the override retention flag for this retention plan.

ClassificationPolicy

String

The name of a classification policy with which the retention plan is associated.

HasFolders

Boolean

Whether the retention plan defines any retention folders. If true, the Folders and FolderXml properties contain information about the retention folders.

The Folders property contains the information as tabulated text, which you can format using Format-Table.

The FolderXml property contains the information as XML, which you can output to a file.

DisableStorageExpiry

SwitchParameter

Whether you have chosen to disable Storage Expiry in any archive that has retention folder issues.

Related cmdlets