Set-VBRSimpleRetentionPolicy
Short Description
Modifies a retention policy for backup copy jobs that process backups stored on external repositories.
Applies to
Platform: VMware, Hyper-V
Product Edition: Community, Standard, Enterprise, Enterprise Plus, Veeam Universal License
Syntax
Set-VBRSimpleRetentionPolicy -RetentionPolicy <VBRSimpleRetentionPolicy> [-RestorePoints <int>] [<CommonParameters>] |
Detailed Description
This cmdlet modifies a retention policy for a backup copy jobs that process backups stored on external repositories.
Parameters
Parameter | Description | Required | Position | Accept |
---|---|---|---|---|
RetentionPolicy | Specifies a retention policy for a backup copy job. The cmdlet will modify this policy. | True | Named | True (ByValue) |
RestorePoints | Specifies a number of restore points. | False | Named | False |
<CommonParameters>
This cmdlet supports Microsoft PowerShell common parameters. For more information on common parameters, see the About CommonParameters section of Microsoft Docs.
Return Type
Example
This example shows how to modify a retention policy for a backup copy job. The target backup repository will keep the last 5 restore points.
- Run Get-VBRJob to get the backup copy job. Save the result to the $job variable.
- Run Get-VBRRetentionPolicy with the $job variable. Save the result to the $policy variable.
- Run Set-VBRSimpleRetentionPolicy with the $policy variable.
$job = Get-VBRJob -Name "EC2 BCJ 01" $policy = Get-VBRRetentionPolicy -Job $job Set-VBRSimpleRetentionPolicy -RetentionPolicy $policy -RestorePoints 5 |
Related Commands