open-vault/website/content/api-docs/system/ha-status.mdx

67 lines
1.7 KiB
Plaintext

---
layout: api
page_title: /sys/ha-status - HTTP API
description: The `/sys/ha-status` endpoint is used to check the HA status of a Vault cluster.
---
# `/sys/ha-status`
The `/sys/ha-status` endpoint is used to check the HA status of a Vault cluster.
It lists the active node and the peers that it's heard from since it became active.
## HA Status
This endpoint returns the HA status of the Vault cluster.
| Method | Path |
| :----- | :----------------- |
| `GET` | `/sys/ha-status` |
### Sample Request
```shell-session
$ curl \
--header "X-Vault-Token: ..." \
http://127.0.0.1:8200/v1/sys/ha-status
```
### Sample Response
```json
{
"Nodes": [
{
"hostname": "node1",
"api_address": "http://10.0.0.2:8200",
"cluster_address": "https://10.0.0.2:8201",
"active_node": true,
"last_echo": null,
"version": "1.11.0",
"upgrade_version": "1.11.0",
"redundancy_zone": "a"
},
{
"hostname": "node2",
"api_address": "http://10.0.0.3:8200",
"cluster_address": "https://10.0.0.3:8201",
"active_node": false,
"last_echo": "2021-11-29T10:29:09.202235-05:00",
"version": "1.11.0",
"upgrade_version": "1.11.0",
"redundancy_zone": "a"
},
{
"hostname": "node3",
"api_address": "http://10.0.0.4:8200",
"cluster_address": "https://10.0.0.4:8201",
"active_node": false,
"last_echo": "2021-11-29T10:29:07.402548-05:00",
"version": "1.11.0",
"upgrade_version": "1.11.0",
"redundancy_zone": "a"
}
]
}
```
Note that in the above sample response, `upgrade_version` and `redundancy_zone` are Enterprise-only fields.