‎07-16-2015 05:24 PM
$TotalGB = @{Name="Capacity(GB)";expression={[math]::round(($_.Capacity/ 1073741824),2)}}
$FreeGB = @{Name="FreeSpace(GB)";expression={[math]::round(($_.FreeSpace / 1073741824),2)}}
$FreePerc = @{Name="Free(%)";expression={[math]::round(((($_.FreeSpace / 1073741824)/($_.Capacity / 1073741824)) * 100),0)}}
function get-mountpoints {
$volumes = Get-WmiObject -computer $server win32_volume #| Where-object {$_.DriveLetter -eq $null}
$volumes | Select SystemName, Label, DriveLetter, $TotalGB, $FreeGB, $FreePerc | Format-Table -AutoSize
}
$servers = @('server01','server02','server05','server06','server10','server11','server12','server15','server16','server17','server18')
foreach ($server in $servers){
get-mountpoints
}
‎07-17-2015 01:21 PM
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now