Plugins > vCenter Server 5.5.3 > VcClusterComputeResource > clusterEnterMaintenanceMode

Method clusterEnterMaintenanceMode(VcHostSystem[] host, VcOptionValue[] option)

The API takes a list of hosts in the cluster as input, and returns a list of hosts in "ClusterMaintenanceResult" that the server can successfully evacuate given the existing constraints in the cluster, such as HA, FT, Vmotion compatibility, reservations, affinity rules, etc. The client is allowed to pass all hosts in the cluster to the API, even though all of them cannot enter maintenance mode at the same time. The list returned from the API contains the largest number of hosts that the server can evacuate simultaneously. The client can then request to enter each host in the returned list into maintenance mode. The client can specify an integer "DemandCapacityRatioTarget" option in the "option" parameter. The allowed values of the option range from 40 to 200, and the default value is 100. This option controls how much resource overcommitment the server should make in consolidating the VMs onto fewer hosts. A value of 100 means the server will keep the same amount of powered-on capacity as the current VM demands. A value less than 100 means undercommitted resources. A value greater than 100 means overcommitted resources. The hosts are recommended based on the inventory at the time of the API invocation. It is not guaranteed that the actual enter-maintenance tasks on the hosts will succeed, if the inventory changes after the API returns, or if vmotions fail due to unexpected conditions. For possible exceptions thrown by the necessary relocate operations, see VcVirtualMachine.




Name Type Description
host VcHostSystem[] The array of hosts to put into maintenance mode.
option VcOptionValue[] An array of <a href="VcOptionValue.html">VcOptionValue</a> options for this query. The specified options override the advanced options in <a href="VcClusterDrsConfigInfo.html">VcClusterDrsConfigInfo</a>.