BackupCycles value and RetainDays value?

PowerShell script exchange

BackupCycles value and RetainDays value?

Veeam Logoby ekisner » Wed Feb 18, 2015 7:25 pm

It appears that all of my backup-to-disk jobs are all keeping multiple full backups on the disk - I can certainly see the logic, but it has filled up the storage array being used for this purpose.

In my investigation and testing, I started looking at the job.options.BackupStorageOptions object. It has a BackupCycles and a RetainDays value in it.

To me, a "Backup Cycle" would be one pass of a full backup, thus a job with a BackupCycles set to 7 would keep 7 full backups plus the incrementals in between. Is this understanding correct? Is the RetainDays for identifying how long to keep incrementals?

I ask because after setting it to 1, it changed the "restore points" from 7 to 1 within the wizard. I would have taken restore points to include incrementals. If my understanding of that was flawed and it is indeed full backups, I might suggest changing the label from restore points (of which 7 seemed logical... day 1 is the full, days 6-7 would be incremental, rinse and repeat) to "Backup Cycles" or similar.

I'm running a job on a small VM now to see what changing the BackupCycles does, but until it finishes and just in case the results are inconclusive, I thought I'd turn to the forums.
ekisner
Expert
 
Posts: 131
Liked: 31 times
Joined: Thu Jul 26, 2012 8:04 pm
Full Name: Erik Kisner

Re: BackupCycles value and RetainDays value?

Veeam Logoby ekisner » Wed Feb 18, 2015 8:48 pm

It appears that the RetainCycles value was indeed what I thought it was. Sadly... in my OP I referred to it as "BackupCycles".

For anyone who is interested:
Code: Select all
$jobs = Get-VBRJob | ?{$_.someparameter -match "yourcriteria"}
foreach ($job in $jobs){
  $options=$job.GetOptions()
  $options.BackupStorageOptions.RetainCycles =1
  $job.SetOptions($options)
}
ekisner
Expert
 
Posts: 131
Liked: 31 times
Joined: Thu Jul 26, 2012 8:04 pm
Full Name: Erik Kisner

Re: BackupCycles value and RetainDays value?

Veeam Logoby v.Eremin » Thu Feb 19, 2015 12:30 pm

RetainCycles is referred to retention settings or number of restore points that should be kept on disk. Just out of curiosity - what backup mode you're currently using? Thanks.
v.Eremin
Veeam Software
 
Posts: 13296
Liked: 974 times
Joined: Fri Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin


Return to PowerShell



Who is online

Users browsing this forum: No registered users and 5 guests