Verify VAAI settings with PowerCLI

I recently had a need to validate that all hosts in a specific vCenter had appropriate vStorage API for Array Integration (VAAI) settings. I didn’t want to change the values, I was just looking for the existing values. This short code will do just that:

[cc lang=”powershell”]
$myreport = @()
Get-VMHost | %{
$DataMoverHardwareAcceleratedMove = $_ | Get-VMHostAdvancedConfiguration -Name DataMover.HardwareAcceleratedMove
$VMFS3HardwareAcceleratedLocking = $_ | Get-VMHostAdvancedConfiguration -Name VMFS3.HardwareAcceleratedLocking
$DataMoverHardwareAcceleratedInit = $_ | Get-VMHostAdvancedConfiguration -Name DataMover.HardwareAcceleratedInit
$myreport += new-object psobject -property @{
Host = $_.Name
DataMoverHardwareAcceleratedMove = [string]$DataMoverHardwareAcceleratedMove.Values
VMFS3HardwareAcceleratedLocking = [string]$VMFS3HardwareAcceleratedLocking.Values
DataMoverHardwareAcceleratedInit = [string]$DataMoverHardwareAcceleratedInit.Values

The resulting output will list the setting for each option value for each host. Note: 0 = disabled and 1 = enabled.

If you need to make changes to these values on a large number of hosts, check out this article:

This entry was posted in Scripting, Virtualization. Bookmark the permalink.

Leave a Reply

Your email address will not be published.


Notify me of followup comments via e-mail. You can also subscribe without commenting.