PowerShell script exchange
Post Reply
EddieStevensAMT
Lurker
Posts: 1
Liked: never
Joined: Jan 15, 2026 3:17 pm
Full Name: Eddie Stevens
Contact:

Query (used space) in a (Veeam Data Cloud Vault) with PowerShell

Post by EddieStevensAMT »

Is there any way to use PowerShell to query (used space) in a (Veeam Data Cloud Vault)?
I can query (used space) in local vaults using the following command, but the Veeam Cloud Vault always shows a value of (-1).

foreach ($Repo in get-vbrbackuprepository) {write-host "$($Repo.name): $($Repo.GetContainer().CachedTotalSpace.InBytes)"}

LHR01: 58624162398208
NAS01: 34538752606208
NAS02: 69078509158400
Veeam Cloud Vault: -1

I’ve seen a number of posts relating to this, but they are all either out of date, reference cloud vaults hosted by a third party, or do not apply to Veeam 12 or 13. The information is available in the Veeam console; it shows up under Backup Repositories under Backup Infrastructure. I am really hoping there is a PowerShell command to simply query the (used space) in a (Veeam Data Cloud Vault). Alternatively, does Veeam cache that information locally? Is there a way to query what it displays on the Backup Repositories screen?
david.domask
Veeam Software
Posts: 3235
Liked: 751 times
Joined: Jun 28, 2016 12:12 pm
Contact:

Re: Query (used space) in a (Veeam Data Cloud Vault) with PowerShell

Post by david.domask »

Hi Eddie, welcome to the forums.

CachedTotalSpace relates to the capacity of a repository, not the used space. With the CachedTotalSpace and CachedFreeSpace values you can estimate the used space, but you can also query it with another unsupported method:

[Veeam.Backup.Core.CBackupRepository]::GetRepositoryBackupsSize()

This accepts a Repository GUID as an argument, and returns total size of backups written to the repository.
David Domask | Product Management: Principal Analyst
Post Reply

Who is online

Users browsing this forum: andrei.pascu and 92 guests