VMs with Ballooned or Swapped memory

Here is a short script that will list all VMs that have Swapped & Ballooned Memory, it can be useful for tracking down VMs experiencing performance issues on clusters running into contention issues

get-vm | select name,
@{N='MemoryMB';E={$_.MemoryMB}},
@{N='SwappedMemory';E={$_.ExtensionData.Summary.QuickStats.SwappedMemory}},
@{N='Ballooned';E={$_.ExtensionData.Summary.QuickStats.BalloonedMemory}} | Where {$_.SwappedMemory -ne "0" -or $_.Ballooned -ne "0"} | ft

 561 total views,  3 views today

Leave a Reply

Your email address will not be published. Required fields are marked *