esx settings defaults clusters policies apply: set
This API will set the configured policy specification.
Request:
HTTP request
PUT https://{server}/api/esx/settings/defaults/clusters/policies/apply
{
"disable_dpm" : true,
"evacuate_offline_vms" : true,
"failure_action" : {
"retry_delay" : 1,
"retry_count" : 1,
"action" : "FAIL"
},
"pre_remediation_power_action" : "POWER_OFF_VMS",
"disable_hac" : true,
"enable_quick_boot" : true
}
"disable_dpm" : true,
"evacuate_offline_vms" : true,
"failure_action" : {
"retry_delay" : 1,
"retry_count" : 1,
"action" : "FAIL"
},
"pre_remediation_power_action" : "POWER_OFF_VMS",
"disable_hac" : true,
"enable_quick_boot" : true
}
Body Parameters:
Name | Type | Description |
---|---|---|
bold = required | ||
- | configured_policy_spec | The policy that needs to be configured. |
-.failure_action | failure_action | What action is to be taken if entering maintenance mode fails on a given host of the cluster. Optional. If unset, configured value would be unset. |
-.failure_action.action | string | What action (FAIL , RETRY ) is to be taken if entering maintenance mode fails on a single host within the cluster. Defines the actions to be taken when entering maintenance mode fails on a single host within the cluster. Value is one of:FAIL: Fail the apply operation RETRY: Retry the task esx.settings.defaults.clusters.policies.apply.failure_action.retry_count number of times on the failed host after esx.settings.defaults.clusters.policies.apply.failure_action.retry_delay. |
-.failure_action.retry_delay | long | Time to wait to retry the failed operation in seconds. Optional. It is only relevant when action has value [RETRY]. This field is optional and it is only relevant when the value of action is RETRY. |
-.failure_action.retry_count | long | Number of times to retry the failed operation. Optional. It is only relevant when action has value [RETRY]. This field is optional and it is only relevant when the value of action is RETRY. |
-.pre_remediation_power_action | string | Specifies what should be done to the power state of the VM before entering maintenance mode. Optional. If unset, configured value would be unset. |
-.enable_quick_boot | boolean | Enable Quick Boot during remediation in the cluster. Optional. If unset, configured value would be unset. |
-.disable_dpm | boolean | Disable DPM on the cluster. Optional. If unset, configured value would be unset. |
-.disable_hac | boolean | Disable HA Admission control on the cluster. Optional. If unset, configured value would be unset. |
-.evacuate_offline_vms | boolean | Evacuate powered off/suspended VMs when attempting maintenance mode. Optional. If unset, configured value would be unset. |
Response:
HTTP Status Code: 204
Headers:
NoneType:
NoneErrors:
HTTP Status Code | Type | Description |
---|---|---|
500 | error | If there is an unknown internal error. The accompanying error message will give more details about the failure. |
400 | invalid_argument | If invalid value is provided. |
503 | service_unavailable | If the service is not available. |
401 | unauthenticated | If the caller is not authenticated. |