How to change all storage paths of all datastores on a host in VCenter

vmware_view_pilot-5132020[1]This will only work once a host has been added to Vcenter.

Use Vmware CLI to run this with the variables in Square Brackets edited out

This will change from Multipath to Round Robin

Connect-VIServer [VCENTER-SERVER-ADDRESS]
 
$hostview = Get-View -Viewtype HostSystem  –filter @{“Name”=[Fully qualified name of server]}
$storageSystem = Get-View $hostview.ConfigManager.StorageSystem 
$policy = new-object VMware.Vim.HostMultipathInfoLogicalUnitPolicy
#$policy.policy = "VMW_PSP_MRU" 
$policy.policy = "VMW_PSP_RR"
$storageSystem.StorageDeviceInfo.MultipathInfo.lun | foreach { $storageSystem.SetMultipathLunPolicy($_.ID, $policy) }
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading...