Backup size for Veeam Agent for Windows

PowerShell script exchange

Backup size for Veeam Agent for Windows

Veeam Logoby kiemann » Wed Jul 26, 2017 2:49 pm

Hallo, i have a question,

in VBR I could show me the backup size of an Veeam Agent for Windows Backup. Could I do this also with powershell?
kiemann
Novice
 
Posts: 3
Liked: never
Joined: Fri Jul 21, 2017 9:58 am
Full Name: Stefan Kiemann

Re: Backup size for Veeam Agent for Windows

Veeam Logoby v.Eremin » Thu Jul 27, 2017 11:23 am

Have you tried already Get-VBRBackup cmdlet?
v.Eremin
Veeam Software
 
Posts: 13266
Liked: 968 times
Joined: Fri Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin

Re: Backup size for Veeam Agent for Windows

Veeam Logoby kiemann » Thu Jul 27, 2017 1:23 pm

Thanks for your help.

Yes I use Get-VBRBackup, but with Get-VBRBackup I did not get any inforamtion about backup size. The only size I get is wenn I use Get-VBRRestorePoint. Their is a variable ApproxSize but this value is without dedup and compression.
kiemann
Novice
 
Posts: 3
Liked: never
Joined: Fri Jul 21, 2017 9:58 am
Full Name: Stefan Kiemann

Re: Backup size for Veeam Agent for Windows

Veeam Logoby v.Eremin » Thu Jul 27, 2017 2:17 pm

What about the following one-liner:

Code: Select all
Get-VBRBackup | Select @{N="Job Name";E={$_.Name}}, @{N="Size (GB)";E={[math]::Round(($_.GetAllStorages().Stats.BackupSize | Measure-Object -Sum).Sum/1GB,1)}} | Format-Table -AutoSiz

Thanks.
v.Eremin
Veeam Software
 
Posts: 13266
Liked: 968 times
Joined: Fri Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin

Re: Backup size for Veeam Agent for Windows

Veeam Logoby kiemann » Fri Jul 28, 2017 9:03 am

Thank you for your help. This was what i need $_.GetAllStorages().Stats.BackupSize
kiemann
Novice
 
Posts: 3
Liked: never
Joined: Fri Jul 21, 2017 9:58 am
Full Name: Stefan Kiemann

Re: Backup size for Veeam Agent for Windows

Veeam Logoby v.Eremin » Fri Jul 28, 2017 12:57 pm

You're welcome. As always with PowerShell it's all about discovery process. I typically assign this or that object to a variable, and then start digging deeper into the properties and methods it has, trying to find information I need. Thanks.
v.Eremin
Veeam Software
 
Posts: 13266
Liked: 968 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 4 guests