Reports REST API
Description – manages UFM reports by starting, stopping, and retrieving them
Request URL – /ufmRest/reports
Main operations
Start a report
Stop a report
Get a report
Get the last report
Description – start a new report
Request URL – POST /ufmRest/reports/<report_type>
Request Content Type – Application/json
Note
report_type should be one of the following: Fabric_Health, UFM_Health, or Topology_Compare
Request Data
Topology_Compare reports – request data should be the topology file to which UFM will compare the current topology
UFM_Health reports – N/A
Fabric_Health reports:
{
"duplicate_nodes"
:true
,"map_guids_desc"
:false
,"sm_state"
:true
,"firmware"
:false
,"cables"
:false
,"non_opt_links"
:true
,"non_opt_speed_width"
:true
,"link_speed"
:"ALL"
,"link_width"
:"ALL"
,"duplicate_zero_and_lids"
:false
,"ufm_alarms"
:true
,"iblr_ber_events"
:true
,"iblr_links_events"
:true
,"health_policy_devices"
:true
}NoteAt least 1 parameter should be passed to the API.
Name
Values
Default
Dependent On*
Description
duplicate_nodes
Boolean
False
Lists all nodes with same node description. Does not include switches with the same description.
map_guids_desc
Boolean
False
duplicate_nodes
Enables the usage of a mapping file (between node GUID and node description) when running duplicate node description analysis of the fabric
ufm_alarms
Boolean
False
Lists all open alarms in UFM
sm_state
Boolean
False
Verifies that:
There is only one active (master) Subnet Manager in the fabric;
The master is selected according to highest priority and lowest port GUID;
The report lists all SMs in the fabric with their attributes
firmware
Boolean
False
Checks for firmware inconsistencies. For each device model in the fabric, the test finds the latest installed version of the firmware and reports devices with older versions.
cables
Boolean
False
Reports cable information as stored in EEPROM on each port: cable vendor, type, length and serial number
cables_errors_only
Boolean
False
Cables
errors_only flag for cables
non_opt_links
Boolean
False
Performs a full-fabric discovery and reports 'non-responsive' ports with their path
non_opt_speed_width
Boolean
False
Enables link speed and link width checks
link_speed
["ALL", "SDR", "DDR", "QDR",
"FDR_10", "FDR", "EDR"]
"ALL"
non_opt_speed_width
Checks if link speed is optimally used
Link_width
["ALL", "SDR", "DDR", "QDR",
"FDR_10", "FDR", "EDR"]
"ALL"
non_opt_speed_width
Checks if link width is optimally used
iblr_links_events
Boolean
False
IBLR plugin deployment
Shows link flapping events, generated by IBLR plugin
iblr_ber_events
Boolean
False
IBLR Plugin deployment
Shows BER related events, generated by IBLR plugin
health_policy_devices
Boolean
False
Shows current defined ufm health policy ports
NoteFor example: “map_guids_desc” is dependent on “duplicate_nodes” in the sense that to set “map_guids_desc”, “duplicate_nodes” has to be set to True.
Response
{ "report_id": 4 }
Status Codes
200 – OK
400 – BAD REQUEST
Description – stops a report using its ID
Request URL – DELETE /ufmRest/reports/<report_id>
Request Content Type – Application/json
Response – N/A
Status Codes
200 – OK
400 – BAD REQUEST
Description – retrieve report's result using its ID
Request URL – GET /ufmRest/reports/<report_id>
Request Content Type – Application/json
Response
{ "date": "2018-04-07 05:38:13", "sections": [ { "status": { "severity": "Info", "value": "" }, "elements": [ { "Warnings": "0", "Errors": "0", "Fabric Test": "Non-unique Node Descriptions", "Total": "0" }, { "Warnings": "0", "Errors": "0", "Fabric Test": "Firmware Versions", "Total": "0" }, { "Warnings": "0", "Errors": "0", "Fabric Test": "Total:", "Total": "0" } ], "description": "", "title": "Report Summary" }, { "status": { "severity": "Info", "value": "" }, "elements": [ { "Count": "1", "Device Type": "EDR", "Non Active Ports": "32", "Active Ports": "4", "Total Ports": "36" }, { "Count": "1", "Device Type": "SX6036", "Non Active Ports": "25", "Active Ports": "11", "Total Ports": "36" }, { "Count": "16", "Device Type": "Computer", "Non Active Ports": "0", "Active Ports": "21", "Total Ports": "21" }, { "Count": "5", "Device Type": "MSB7700", "Non Active Ports": "156", "Active Ports": "24", "Total Ports": "180" }, { "Count": "23", "Device Type": "Total:", "Non Active Ports": "213", "Active Ports": "60", "Total Ports": "273" } ], "description": "", "title": "Fabric Summary" }, { "status": { "severity": "Info", "value": "Completed Successfully." }, "description": "Lists all nodes with same node description. Does not include switches with the same description. ", "title": "Non-unique Node Descriptions" }, { "status": { "severity": "Info", "value": "Completed Successfully." }, "description": "Checks for firmware inconsistencies. For each device model in the fabric, the test finds the latest installed version of the firmware and reports devices with older versions. ", "title": "Firmware Versions" } ], "Created by": "admin", "title": "Fabric Health Report" }
Status Codes
200 – OK
202 – ACCEPTED (processing report)
400 – BAD REQUEST
Description – get the results of the last generated report using its type
Request URL – GET /ufmRest/reports/last_report/<report_type>
Note
report_type should be one of the following: Fabric_Health, UFM_Health, or Topology_Compare
Request Content Type – Application/json
Response – See response in the previous chapter
Status Codes
200 – OK
400 – BAD REQUEST