some of my reporting scripts stopped working because of the missing Space Properties of the BackupRepository Object.
v10 Example:
Code: Select all
# Get All Backup Repositories Advanced
[Array]$RepoList = Get-VBRBackupRepository | Where-Object {$_.Type -ne "SanSnapshotOnly"}
[Array]$ScaleOuts = Get-VBRBackupRepository -ScaleOut
if ($ScaleOuts) {
foreach ($ScaleOut in $ScaleOuts) {
$Extents = Get-VBRRepositoryExtent -Repository $ScaleOut
foreach ($Extent in $Extents) {
$RepoList = $RepoList + $Extent.repository
}
}
}
$RepoList | Select-Object Name, Path, `
@{Name="CachedTotalSpaceGB"; Expression= {[Math]::Round([Decimal]$_.info.CachedTotalSpace/1GB,2)}}, `
@{Name="CachedFreeSpaceGB"; Expression= {[Math]::Round([Decimal]$_.info.CachedFreeSpace/1GB,2)}} | Format-Table -AutoSize
Best regards
Markus