Using DRS recommendations
To retrieve the available DRS recommendations from the provided clusters, you can use the Get-DrsRecommendation
cmdlet. This is useful if you configure the DrsAutomationLevel
on your cluster as Manual
or PartiallyAutomated
. The syntax of the Get-DrsRecommendation
cmdlet is as follows:
Get-DrsRecommendation [[-Cluster] <Cluster[]>] [-Refresh]
[-Priority <Int32[]>] [-Server <VIServer[]>] [<CommonParameters>]
The Get-DrsRecommendation
cmdlet has no required parameters.
In the following example, you will retrieve all the DRS recommendations for all the clusters:
PowerCLI C:\ > Get-DrsRecommendation Priority Recommendation Reason -------- -------------- ------ 2 Migrate VM 'VM1' from host... Fix soft VM/host affinity r...
To apply a DRS recommendation, you can use the Invoke-DrsRecommendation
cmdlet. This cmdlet has the following syntax:
Invoke-DrsRecommendation [-DrsRecommendation...