#Connect-VIServer -Server P111vc01.st.com
$esxcli = Get-EsxCli
Get-VMHost btpesxu4c1b6.st.com| Get-ScsiLun -CanonicalName "naa.500*" | Set-ScsiLun -MultipathPolicy "roundrobin"
Get-VMHost btpesxu4c1b6.st.com| Get-ScsiLun -CanonicalName "naa.60002ac0000000000000003400006056*" | Set-ScsiLun -MultipathPolicy "roundrobin"
#esxcli storage nmp satp rule add -s "VMW_SATP_ALUA" -P "VMW_PSP_RR" -O iops=100 -c "tpgs_on" -V "3PARdata" -M "VV" -e "HP 3PAR Custom iSCSI/FC/FCoE ALUA Rule"
$esxcli.storage.nmp.device.list() | where {$_.device -like "naa.500*"} | %{
$configBefore = $esxcli.storage.nmp.psp.roundrobin.deviceconfig.get($_.device)
$esxcli.storage.nmp.psp.roundrobin.deviceconfig.set(0, 1, $_.device, [long]100, "iops", $false)
$configAfter = $esxcli.storage.nmp.psp.roundrobin.deviceconfig.get($_.device)
# Uncomment the following lines if you want to report the settings
$configBefore
$configAfter
}
$esxcli = Get-EsxCli
Get-VMHost btpesxu4c1b6.st.com| Get-ScsiLun -CanonicalName "naa.500*" | Set-ScsiLun -MultipathPolicy "roundrobin"
Get-VMHost btpesxu4c1b6.st.com| Get-ScsiLun -CanonicalName "naa.60002ac0000000000000003400006056*" | Set-ScsiLun -MultipathPolicy "roundrobin"
#esxcli storage nmp satp rule add -s "VMW_SATP_ALUA" -P "VMW_PSP_RR" -O iops=100 -c "tpgs_on" -V "3PARdata" -M "VV" -e "HP 3PAR Custom iSCSI/FC/FCoE ALUA Rule"
$esxcli.storage.nmp.device.list() | where {$_.device -like "naa.500*"} | %{
$configBefore = $esxcli.storage.nmp.psp.roundrobin.deviceconfig.get($_.device)
$esxcli.storage.nmp.psp.roundrobin.deviceconfig.set(0, 1, $_.device, [long]100, "iops", $false)
$configAfter = $esxcli.storage.nmp.psp.roundrobin.deviceconfig.get($_.device)
# Uncomment the following lines if you want to report the settings
$configBefore
$configAfter
}
No comments:
Post a Comment