Obtaining health check data of Developer Portal servers by using a REST API call
You can check the status of a Developer Portal cluster by calling a cluster health REST API.
About this task
Procedure
To call the cluster health REST API, complete the following steps:
Example
{
"servers" : [
{
"rc" : 0,
"ip" : "1.2.3.4",
"hostname" : "portalnodename",
"version" : "5.0.7.2-20170629-1751",
"installDirectory" : "/",
"os" : "Ubuntu 16.04",
"uptime" : 175636,
"cpu" : {
"cpus" : 4,
"usage" : 61,
"load1" : 2.58,
"load5" : 2.88,
"load15" : 2.90
},
"disk" : {
"free" : 81952,
"used" : 18555,
"total" : 100507
},
"ram" : {
"free" : 7617,
"used" : 8431,
"total" : 16048
},
"swap" : {
"free" : 1000,
"used" : 1047,
"total" : 2047
},
"webHits" : 7,
"transactions" : 39560
},
{
"rc" : 0,
"ip" : "1.2.3.5",
"hostname" : "portalnodename",
"version" : "5.0.7.2-20170629-1751",
"installDirectory" : "/",
"os" : "Ubuntu 16.04",
"uptime" : 679078,
"cpu" : {
"cpus" : 4,
"usage" : 64,
"load1" : 3.71,
"load5" : 3.54,
"load15" : 3.16
},
"disk" : {
"free" : 82300,
"used" : 18207,
"total" : 100507
},
"ram" : {
"free" : 6474,
"used" : 9574,
"total" : 16048
},
"swap" : {
"free" : 1563,
"used" : 484,
"total" : 2047
},
"webHits" : 8,
"transactions" : 50376
},
{
"rc" : 0,
"ip" : "1.2.3.6",
"hostname" : "portalnodename",
"version" : "5.0.7.2-20170629-1751",
"installDirectory" : "/",
"os" : "Ubuntu 16.04",
"uptime" : 679160,
"cpu" : {
"cpus" : 4,
"usage" : 66,
"load1" : 3.26,
"load5" : 3.07,
"load15" : 2.96
},
"disk" : {
"free" : 82921,
"used" : 17586,
"total" : 100507
},
"ram" : {
"free" : 5607,
"used" : 10441,
"total" : 16048
},
"swap" : {
"free" : 1470,
"used" : 577,
"total" : 2047
},
"webHits" : 3,
"transactions" : 37069
}
]
}
The
following example shows the server array entry when a server cannot be
contacted:{
"rc" : 255,
"ip" : "1.2.3.4",
"error" : "Host key verification failed.\r"
}