Guys, looking for a script to list Multipath Policy and IOPS value for our datastores. I can find many that will give me the mp policy but not the IOPS value.
Any help would be much appreciated...
Which IOPS value did you have in mind ?
Do you mean to calculate it from the Realtime performance data, as I did in Get the maximum IOPS ?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Hey Luc, I'm looking for the value that we have set on the datastore
We have an Active \ Active array so we set the mutipath to Round Robin, then set to IOPS=1
as per this article...
VMware KB: Adjusting Round Robin IOPS limit from default 1000 to 1
Try like this
foreach($esx in Get-VMHost){
$esxcli = Get-EsxCli -VMHost $esx
$esxcli.storage.nmp.device.list() |
Select @{N='VMHost';E={$esx.Name}},Device,
@{N='PathPolicy';E={($_.PathSelectionPolicyDeviceConfig | Select-String -Pattern 'policy=(?<policy>\w+),' -AllMatches).Matches.Groups[1].Value}},
@{N='IOPS';E={($_.PathSelectionPolicyDeviceConfig | Select-String -Pattern 'iops=(?<iops>\d+),' -AllMatches).Matches.Groups[1].Value}}
}
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Perfect LucD... this is exactly what I'm looking for ...
in this script how to add Datacenter name, host connected to list of datastores, and host is in which cluster.