I would like to get high threshold values for all interfaces monitored by my interface_traffic, without GUI.
So I would like to parse probe config (using 3rd party parser) but unsuccessful at re-shaping / re-formatting.
(*) This is just idea, not meant there is no other ways. If you have better idea, welcomed and appreciated.
A Rest API call to get probe config, to produce probe config in JSON output.
Probe Calls - CA Unified Infrastructure Management Probes - CA Technologies Documentation
After you get output in JSON format, send it to jq. (a free JSON parser, jq )
For jq download and instructions, please see jq site (jq )
cURL based script example
|Get high threshold values for all interfaces monitored by my interface_traffic probe.|
|curl -H "Accept: application/json" -H "Context-type: application/json" \|
-X GET http://<ump>:<port>/rest/probe/<domain>/<hub>/<robot>/interface_traffic/config \
-u <user>:<password> \
| jq -c '.probeConfigKey | [.key, .value]' \
| grep "/interfaces/" \
| grep "threshold_high" \
Here is a screenshot.
In this example, "threshold_high" is key that I'm looking for.
It helps me to confirm specific key (threshold values for every interfaces) for mass target, without interacting on probe GUI.
This example is LINUX base, I prefer LINUX as workstation to run my script as very easy to add extra formatting / filtering via pipe.
script example attached.