Quantcast
Channel: VMware Communities: Message List
Viewing all articles
Browse latest Browse all 150956

Re: DefaultPSP Change Through PowerCLI/Host Profiles doesn't stick...

$
0
0

Well I found Set Default PSP Round Robin ESXi 5.0U1, and it resolved my issue. by the following.....

 

 

$vHs = Get-VMHost

 

ForEach($vH in $vHs){

    #Getting ESX CLI for each Host

    $vHcli = Get-EsxCli -VMHost $vH

  

    #Does it have the correct PSP for IBM SVC

    $SVC = $vHcli.storage.nmp.satp.list() | Where {$_.Name -eq "VMW_SATP_SVC" -and $_.DefaultPSP -ne "VMW_PSP_RR"} | Select @{N="Cluster";E={$vH.Parent.Name}},@{N="VMHost";E={$vH.Name}},DefaultPSP,Name

  

    If($SVC.Name -eq "VMW_SATP_SVC" -and $SVC.DefaultPSP -ne "VMW_PSP_RR"){

        #Create a low level object that points to the satp namespace:

        $LowLevel = $vHcli.TypeManager.CreateDynamicManagedObject( $vHcli.storage.nmp.satp.id )

 

        #Create a hashtable holding parameter values. Note that here we do not specify value for boot parameter:

        $Params = @{"DefaultPSP" = "VMW_PSP_RR"; satp = "VMW_SATP_SVC"}

 

        #Invoke set operation on the $LowLevel object:

        $LowLevel.InvokeOperation("set",$Params)

    }

  

    #Does it have the correct PSP for Defaults

    $DAA = $vHcli.storage.nmp.satp.list() | Where {$_.Name -eq "VMW_SATP_DEFAULT_AA" -and $_.DefaultPSP -ne "VMW_PSP_RR"} | Select @{N="Cluster";E={$vH.Parent.Name}},@{N="VMHost";E={$vH.Name}},DefaultPSP,Name

  

    If($DAA.Name -eq "VMW_SATP_DEFAULT_AA" -and $DAA.DefaultPSP -ne "VMW_PSP_RR"){

        #Create a low level object that points to the satp namespace:

        $LowLevel = $vHcli.TypeManager.CreateDynamicManagedObject( $vHcli.storage.nmp.satp.id )

 

        #Create a hashtable holding parameter values. Note that here we do not specify value for boot parameter:

        $Params = @{"DefaultPSP" = "VMW_PSP_RR"; satp = "VMW_SATP_DEFAULT_AA"}

 

        #Invoke set operation on the $LowLevel object:

        $LowLevel.InvokeOperation("set",$Params)

    }

}


Viewing all articles
Browse latest Browse all 150956

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>