Retrieving Auto-Failover Settings
- reference
Use the /settings/autoFailover endpoint to get the current auto-failover settings.
Description
The GET /settings/autoFailover HTTP method and URI retrieve auto-failover settings for the cluster.
Auto-failover settings are global, applying to all nodes in the cluster.
Curl Syntax
curl -X GET http://<ip-address-or-hostname>:8091/settings/autoFailover \
-u <username>:<password>
Required Permissions
You must have one of the following roles to be able to read the auto-failover settings:
-
Full Admin
-
Cluster Admin
-
Read-Only Admin
-
Read-Only Security Admin
-
Security Admin
-
External User Admin
-
Local User Admin
For information about roles, see Role Based Access Control (RBAC).
Responses
- 200 OK
-
The call was successful. Also returns an object containing the current state of the auto-failover settings. See Example for an example of the response.
- 401 Unauthorized
-
The user credentials supplied with the call do not have the correct permissions to read the auto-failover settings.
- 404 Not Found
-
The URL was incorrect.
Example
The following example returns the auto-failover settings for the cluster.
It pipes the output through the jq command to improve readability.
curl -X GET http://localhost:8091/settings/autoFailover \
-u Administrator:password | jq '.'
If successful, execution returns the auto-failover settings for the cluster. For example:
{
"enabled": true,
"timeout": 120,
"count": 0,
"maxCount": 1,
"canAbortRebalance": true
}
The response also contains keys that do not apply to Operational Insights; they are omitted from the example above.
The keys in the object returned in the example are:
-
enabledWhether automatic failover is on (a value oftrue) or off (false). -
timeoutThe number of seconds Operational Insights waits after a node has become unavailable before it performs an automatic failover. This value can be between 5 and 3600. The default value is 120. -
count. The number of nodes that Operational Insights has auto-failed over. Operational Insights resets this value to zero either when the cluster rebalances to remove or rejoin the failed nodes, or when an administrator manually resets the count (see Resetting Auto-Failover). The parameter’s default value is 0. If number of failed-over nodes reaches the maximum count set bymaxCount, Operational Insights refuses to auto-failover more nodes until you reset the count or resolve the auto-failovers with a recovery and rebalance. -
maxCount. The maximum number of nodes that can be auto-failed over at the same time. When the count of auto-failed over nodes reaches this value, Operational Insights does not trigger additional auto-failovers. You must either resolve the auto-failovers through rebalancing the cluster to remove or recover the failed-over nodes or reset the count of failed over nodes. The default value is 1. -
canAbortRebalanceWhether or not Operational Insights can auto-failover a node while a rebalance is taking place. This feature is available in Operational Insights. The value can be eithertrue(the default) orfalse.
See Also
-
For information about setting auto-failover parameters with the REST API, see Enabling and Disabling Auto-Failover.
-
The Operational Insights command line tool setting-autofailover lets you manage auto-failover.
-
For information about managing auto-failover with Operational Insights Web Console, see Node Availability.
-
For information about failover, see Failover.