Sunday, September 19, 2010

Daily PowerCLI Primer - Rescan Hosts for New Storage

Rescan Hosts for New Storage

For a Specific Host:
Connect-VIServer MYVISERVER
Get-VMHost "MyESXHost.mydomain.com"
Get-VMHostStorage -RescanAllHBA

For a Specific Cluster:
Connect-VIServer MYVISERVER
Get-Cluster -name "MY CLUSTER"
Get-VMHost
Get-VMHostStorage -RescanAllHBA

All Hosts in VC:
Connect-VIServer MYVISERVER
Get-VMHost
Get-VMHostStorage –RescanAllHBA

~ Scott march

0 comments:

Post a Comment