I am struggling to find which command I use to set the number of restore points in a job. Can someone please point me in the right place.
Thanks
Frank
-
- Enthusiast
- Posts: 36
- Liked: 2 times
- Joined: May 02, 2018 11:56 am
- Full Name: Frank Tighe
- Contact:
-
- Veeam Software
- Posts: 742
- Liked: 209 times
- Joined: Jan 14, 2016 6:48 am
- Full Name: Anthony Spiteri
- Location: Perth, Australia
- Contact:
Re: Set the amount of restore points
Hey Frank...something like this should work:
Code: Select all
$jobname="J1"
$RestorePointValue="7"
$JobOptions = Get-VBRJobOptions $jobname
$JobOptions.BackupStorageOptions.RetainCycles = $RestorePointsValue
$Jobname | Set-VBRJobOptions -Options $JobOptions
Anthony Spiteri
Regional CTO APJ & Lead Cloud and Service Provider Technologist
Email: anthony.spiteri@veeam.com
Twitter: @anthonyspiteri
Regional CTO APJ & Lead Cloud and Service Provider Technologist
Email: anthony.spiteri@veeam.com
Twitter: @anthonyspiteri
-
- Enthusiast
- Posts: 36
- Liked: 2 times
- Joined: May 02, 2018 11:56 am
- Full Name: Frank Tighe
- Contact:
Re: Set the amount of restore points
Awesome, thank you
-
- Enthusiast
- Posts: 36
- Liked: 2 times
- Joined: May 02, 2018 11:56 am
- Full Name: Frank Tighe
- Contact:
Re: Set the amount of restore points
The example you gave was close but not 100%, and it got me there. This is what i did that works.
Code: Select all
$RestorePoints = 21
$Joboptions = get-vbrjob -Name JobName | Get-VBRJobOptions
$JobOptions.BackupStorageOptions.RetainCycles = $RestorePoints
get-vbrjob -Name JobName | Set-VBRJobOptions -Options $JobOptions
Who is online
Users browsing this forum: No registered users and 18 guests