V Sanhealth Check APIs
APIs for managing vSAN health checks
Table of Contents
1. Get vSAN health check status
- Get vSAN health check status API is used to fetch vSAN health check status.
1.1. Prerequisites
The following data is required:
- ID of a domain
The following data is optional:
- Status of health check [ENABLED / DISABLED]
1.2. Steps
- Invoke the API.
cURL Request
$ curl 'https://sfo-vcf01.rainpole.io/v1/domains/716c1e7e-9eff-4f1b-b2d8-4193df0d124d/health-checks' -i -X GET \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer etYWRta....'
HTTP Request
GET /v1/domains/716c1e7e-9eff-4f1b-b2d8-4193df0d124d/health-checks HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....
HTTP Response
HTTP/1.1 202 Accepted
Content-Type: application/json
Content-Length: 102
{
"resultId" : "ca0f5c82-6a8b-4ab1-b349-16682b313e78",
"status" : "INPROGRESS",
"result" : [ ]
}
- Poll the vSAN health check status with the ID from the response of the previous API.
cURL Request
$ curl 'https://sfo-vcf01.rainpole.io/v1/domains/716c1e7e-9eff-4f1b-b2d8-4193df0d124d/health-checks/queries/ca0f5c82-6a8b-4ab1-b349-16682b313e78' -i -X GET \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer etYWRta....'
HTTP Request
GET /v1/domains/716c1e7e-9eff-4f1b-b2d8-4193df0d124d/health-checks/queries/ca0f5c82-6a8b-4ab1-b349-16682b313e78 HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 434
{
"resultId" : "ca0f5c82-6a8b-4ab1-b349-16682b313e78",
"status" : "SUCCESS",
"result" : [ {
"id" : "objecthealth",
"name" : "vSAN object health",
"description" : "Checks the health status of all vSAN objects.",
"type" : "VSAN",
"status" : "ENABLED",
"resourceType" : "CLUSTER",
"resourceId" : "7ab924ef-bb93-41fc-aa16-22be41243fd0",
"resourceName" : "68a5afb4-81fe-4551-95f3-f1eec16d02e1"
} ]
}
2. Update vSAN health check status
- Update vSAN health check status API is used to update the vSAN health check status.
2.1. Prerequisites
The following data is required:
ID of the Domain
List of vSAN health check spec
Tip : Refer to: HealthCheckSpec
2.2. Steps
- Invoke the API.
cURL Request
$ curl 'https://sfo-vcf01.rainpole.io/v1/domains/716c1e7e-9eff-4f1b-b2d8-4193df0d124d/health-checks' -i -X PATCH \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer etYWRta....' \
-d '[ {
"id" : "objecthealth",
"name" : "vSAN object health",
"status" : "DISABLED",
"resourceType" : "CLUSTER",
"resourceName" : "68a5afb4-81fe-4551-95f3-f1eec16d02e1"
} ]'
HTTP Request
PATCH /v1/domains/716c1e7e-9eff-4f1b-b2d8-4193df0d124d/health-checks HTTP/1.1
Content-Type: application/json
Accept: application/json
Content-Length: 178
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....
[ {
"id" : "objecthealth",
"name" : "vSAN object health",
"status" : "DISABLED",
"resourceType" : "CLUSTER",
"resourceName" : "68a5afb4-81fe-4551-95f3-f1eec16d02e1"
} ]
HTTP Response
HTTP/1.1 202 Accepted
Content-Type: application/json
Content-Length: 164
{
"id" : "e2de9e81-42af-4d04-a1fd-f6389a0b186e",
"status" : "INPROGRESS",
"resourceStatus" : {
"68a5afb4-81fe-4551-95f3-f1eec16d02e1" : "INPROGRESS"
}
}
- Poll the status of the vSAN health check update with the ID from the response of the previous API.
cURL Request
$ curl 'https://sfo-vcf01.rainpole.io/v1/domains/716c1e7e-9eff-4f1b-b2d8-4193df0d124d/health-checks/tasks/e2de9e81-42af-4d04-a1fd-f6389a0b186e' -i -X GET \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer etYWRta....'
HTTP Request
GET /v1/domains/716c1e7e-9eff-4f1b-b2d8-4193df0d124d/health-checks/tasks/e2de9e81-42af-4d04-a1fd-f6389a0b186e HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 158
{
"id" : "e2de9e81-42af-4d04-a1fd-f6389a0b186e",
"status" : "SUCCESS",
"resourceStatus" : {
"68a5afb4-81fe-4551-95f3-f1eec16d02e1" : "SUCCESS"
}
}
Last updated 2024-03-14 07:59:42 -0700
Operations
GET
Get Vsan Health Check By Domain
Retrieve vSAN Health Check status for a domain by its ID
GET
Get Vsan Health Check By Query ID
Retrieve vSAN Health Check status for a domain and query ID
GET
Get Vsan Health Check By Task ID
Retrieve a vSAN Health Check by task ID
PATCH
Update Vsan Health Check By Domain
Update the vSAN Health Check status for a domain