Retrieving the Measurements Reported by eG Enterprise

To retrieve the measures that are reported by eG Enterprise, by default, administrators can use the eG REST API. The URL can be specified in the following format:

URL: http://<eG manager IP:port>/api/eg/miscservice/getMeasureMapping

Method: POST

Content-Type: application/json

Inputs to be Specified
Parameters Key values Example

Headers

managerurl: Base URL of the eG Manager i.e., http://<IP address of the eG console:Port>

user: eG username or domain/eG username

pwd: Base64 encoded password

Not Applicable

 

Success Response
Type Code Content

JSON

200

{

"IBSubnetMgrTest:smCntSMPsOutstanding": "Outstanding packets",

"IBSubnetMgrTest:smCntSMPsOnWire": "Onwire packets",

"IBSubnetMgrTest:smCntSMPsReceived": "Packets received",

"IBSubnetMgrTest:smCntSMPsSent": "Packets transmitted",

"IBSubnetMgrTest:smCntSMPsUnidirect": "Responseless packets transmitted",

"IBSubnetMgrTest:smCntSMPsUnknownReceived": "Unknown packets received",

.

.

.

}

 

Failure Response
Type Code Content

JSON

401 UNAUTHORIZED

{"code": 401,"error": "Unauthorized user"}

JSON

500 Server Error

{"code": 500,"error": " Server Error "}

Figure 1 : Retrieving the list of measurements using Postman REST Client

Retrieving the Measurements Reported by eG Enterprise using cURL

To retrieve the measures reported by eG Enterprise by monitoring the components in the target environment using cURL, the command should be specified in the following format:

curl -location -request POST "http://<eG Manager IP:Port>/api/eg/miscservice/getMeasureMapping" -H "user:<eG username or domain/eG username>" -H "pwd:Base64 encoded password" -H "managerurl:http://<eG Manager IP:Port>" --data-raw ""

Figure 2 shows an example cURL command for retrieving the measurements reported by eG Enterprise by monitoring the components in the target environment.

Figure 2 : An example cURL command to retrieve the measurements

Figure 3 shows a sample output that retrieves the measurements reported by eG Enterprise using cURL.

Figure 3 : Sample output with the list of measurements supported by eG Enterprise