Enterprise Vault™ PowerShell Cmdlets
- Introducing the Enterprise Vault PowerShell cmdlets
- Archiving: Exchange
- Archiving: FSA
- Archiving: Skype for Business
- Archiving: SMTP
- IMAP access
- Records management
- Retention plans
- Roles-based administration
- Sites and servers
- Tasks and services
- Vault stores and archives
Remove-EVArchive deletes the specified archive and the items that it contains.
Remove-EVArchive does not delete an archive in the following circumstances:
The archive is already marked for deletion.
The vault store that is associated with the archive is in backup mode.
The archive is protected from deletion.
The archive has a status other than Available or Closed.
The archive is being moved.
The archive is associated with one or more Exchange journal mailbox, Exchange public folder, SharePoint site collection, Domino journaling location, SMTP, Skype for Business archiving targets, or SMTP Group Journaling provisioning groups.
This cmdlet prompts you to confirm the removal of the archive.
You cannot stop the deletion process or undo the deletion.
Remove-EVArchive supports the WhatIf switch, which lets you view the changes that would occur without having to apply any of those changes.
By default, Remove-EVArchive does not generate any output. You can use the PassThru switch to return an ArchiveInfo object that provides details of the deleted archive.
Remove-EVArchive is provided by the snap-in
Remove-EVArchive [-ArchiveId] <String> [-PassThru [<SwitchParameter>]] [-Confirm [<SwitchParameter>]] [-WhatIf [<SwitchParameter>]] [<CommonParameters>]
Table: Remove-EVArchive parameters
The ID of the archive to be deleted. You can obtain the ID with the Get-EVArchive cmdlet.
Returns an ArchiveInfo object that provides the details of the archive that you want to delete. By default, this cmdlet does not generate any output.
Prompts you for confirmation before running the cmdlet. To suppress the confirmation prompt, use the syntax -Confirm:$False. You must include a colon ( : ) in the syntax.
Shows what would happen if the cmdlet runs. The cmdlet is not actually run.
The WhatIf switch also displays any errors or warnings that could occur when the command is executed.
Remove-EVArchive -ArchiveId "123...example.com"
Deletes the archive with ID '123...example.com'.
Get-EVArchive -ArchiveName "ArchiveToBeDeleted" | Remove-EVArchive
Pipes the ArchiveInfo object that is obtained from Get-EVArchive to Remove-EVArchive and deletes the archive.
Remove-EVArchive -ArchiveId "123...example.com" -PassThru
Deletes the archive with ID '123...example.com'. It also returns an ArchiveInfo object that provides the details of the deleted archive.
Get-EVArchive -ArchiveName "ArchiveToBeDeleted" | Remove-EVArchive -WhatIf
Pipes the ArchiveInfo object that is obtained from Get-EVArchive to Remove-EVArchive. It then lets you view any errors or warnings that could occur on executing the command. If there are no errors or warnings to display, the command displays the following message:
'This operation will permanently delete archive 'ArchiveToBeDeleted' and all items stored in it. This action overrides the Retention Category option 'Prevent automatic deletion of expired items'. You cannot cancel the operation.'
Get-EVArchive -DeleteProtected:$false | Remove-EVArchive -Confirm:$false
This command uses Get-EVArchive to retrieve all the archives that are not protected from deletion and deletes them using Remove-EVArchive. This command also suppresses the confirmation prompt.
Remove-EVArchive returns no output, or a modified object of the type Symantec.EnterpriseVault.Admin.ArchiveInfo when the -PassThru parameter is specified. Symantec.EnterpriseVault.Admin.ArchiveInfo has the following properties.
Table: Symantec.EnterpriseVault.Admin.ArchiveInfo properties
The ID of the deleted archive.
The name of the deleted archive.
The Enterprise Vault archive type enumeration. The possible values are as follows:
The Enterprise Vault expire items enumeration. The possible values are as follows:
Indicates whether the user could manually delete items from the archive ($false) or not ($true).
Indicates whether the archive contained items that are on legal hold ($true) or not ($false).
The Enterprise Vault archive status enumeration. The possible values are as follows:
The name of the retention plan that was applied to the archive.